|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.vividsolutions.jump.feature.FeatureCollectionWrapper
com.vividsolutions.jump.workbench.model.cache.CachingFeatureCollection
public class CachingFeatureCollection
Caches features to prevent unnecessary queries. Useful for wrapping database-backed FeatureCollections. All calls are delegated to the cache, except for calls to query(envelope).iterator() where (1) the envelope is not within the cache envelope, and (2) the call is made in a non-GUI thread.
| Constructor Summary | |
|---|---|
CachingFeatureCollection(FeatureCollection featureCollection)
|
|
| Method Summary | |
|---|---|
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. |
| Methods inherited from class com.vividsolutions.jump.feature.FeatureCollectionWrapper |
|---|
add, addAll, checkNotWrappingSameClass, clear, getFeatureCollection, getFeatures, getUltimateWrappee, getWrappee, hasWrapper, isEmpty, iterator, remove, remove, removeAll, setFeatureCollection, size |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CachingFeatureCollection(FeatureCollection featureCollection)
| Method Detail |
|---|
public com.vividsolutions.jts.geom.Envelope getEnvelope()
FeatureCollection
getEnvelope in interface FeatureCollectiongetEnvelope in class FeatureCollectionWrapperFeatureCollectionWrapper.getEnvelope()public FeatureSchema getFeatureSchema()
FeatureCollection
getFeatureSchema in interface FeatureCollectiongetFeatureSchema in class FeatureCollectionWrapperFeatureCollectionWrapper.getFeatureSchema()public java.util.List query(com.vividsolutions.jts.geom.Envelope envelope)
FeatureCollection
query in interface FeatureCollectionquery in class FeatureCollectionWrapperenvelope - the envelope to query against
public CachingFeatureCollection setCachingByEnvelope(boolean cachingByEnvelope)
cachingByEnvelope - whether query(envelope).iterator() delegates to the cache if
envelope is within the cache envelopepublic void emptyCache()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||