public class CachingFeatureCollection extends FeatureCollectionWrapper
Constructor and Description |
---|
CachingFeatureCollection(FeatureCollection featureCollection) |
Modifier and Type | Method and Description |
---|---|
void |
emptyCache() |
com.vividsolutions.jts.geom.Envelope |
getEnvelope()
Returns the bounds of this collection.
|
FeatureSchema |
getFeatureSchema()
Returns information about this FeatureCollection
|
java.util.List |
query(com.vividsolutions.jts.geom.Envelope envelope)
A quick search for features, using an envelope comparison.
|
CachingFeatureCollection |
setCachingByEnvelope(boolean cachingByEnvelope)
This setting is ignored if the call to query(envelope).iterator() is made
on the GUI thread, because long queries would make the GUI unresponsive.
|
add, addAll, checkNotWrappingSameClass, clear, getFeatureCollection, getFeatures, getUltimateWrappee, getWrappee, hasWrapper, isEmpty, iterator, remove, remove, removeAll, setFeatureCollection, size
public CachingFeatureCollection(FeatureCollection featureCollection)
public com.vividsolutions.jts.geom.Envelope getEnvelope()
FeatureCollection
getEnvelope
in interface FeatureCollection
getEnvelope
in class FeatureCollectionWrapper
FeatureCollectionWrapper.getEnvelope()
public FeatureSchema getFeatureSchema()
FeatureCollection
getFeatureSchema
in interface FeatureCollection
getFeatureSchema
in class FeatureCollectionWrapper
FeatureCollectionWrapper.getFeatureSchema()
public java.util.List query(com.vividsolutions.jts.geom.Envelope envelope)
FeatureCollection
query
in interface FeatureCollection
query
in class FeatureCollectionWrapper
envelope
- the envelope to query againstpublic CachingFeatureCollection setCachingByEnvelope(boolean cachingByEnvelope)
cachingByEnvelope
- whether query(envelope).iterator() delegates to the cache if
envelope is within the cache envelopepublic void emptyCache()