AbstractFeatureCollection

Method Detail

features

Obtain a SimpleFeatureIterator of the Features within this SimpleFeatureCollection.

The implementation of FeatureIterator must adhere to the rules of
fail-fast concurrent modification. In addition (to allow for
resource backed collections) the SimpleFeatureIterator.close()
method must be called.

openIterator

Factory method used to open an iterator over collection contents
for use by iterator() and features().

If you return an instance of FeatureIterator some effort
is taken to call the FeatureIterator.close() internally, however
we cannot offer any assurance that client code using iterator()
will perform the same check.

accepts

The order of traversal is dependent on the FeatureCollection implementation; some
collections are able to make efficient use of an internal index in order to quickly
visit features located in the same region.

subCollection

The contents of the returned SimpleFeatureCollection are determined by
applying the provider Filter to the entire contents of this
FeatureCollection. The result is "live" and modifications will
be shared.

This method is used cut down on the number of filter based methods
required for a useful SimpleFeatureCollection construct. The FeatureCollections
returned really should be considered as a temporary "view" used to
control the range of a removeAll, or modify operation.

Example Use:

collection.subCollection( filter ).clear();

The above recommended use is agreement with the Collections API precident of
List.subList( start, end ).