Package org.geotools.data.complex
Class IndexedMappingFeatureIterator
Object
IndexedMappingFeatureIterator
- All Implemented Interfaces:
Closeable,AutoCloseable,Iterator<Feature>,IMappingFeatureIterator,FeatureIterator<Feature>
- Direct Known Subclasses:
PartialIndexedMappingFeatureIterator,TotalIndexedMappingFeatureIterator
public abstract class IndexedMappingFeatureIterator
extends Object
implements IMappingFeatureIterator
Base class for Indexed Iterators
- Author:
- Fernando MiƱo (Geosolutions
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected FilterFactoryprotected IndexIdIteratorprotected IndexQueryManagerprotected final FeatureTypeMappingprotected final Queryprotected IndexQueryManager.QueryIndexCoverageprotected FeatureIterator<? extends Feature>protected final AppSchemaDataAccessprotected final Transactionprotected final Filter -
Constructor Summary
ConstructorsConstructorDescriptionIndexedMappingFeatureIterator(AppSchemaDataAccess store, FeatureTypeMapping mapping, Query query, Filter unrolledFilter, Transaction transaction, IndexQueryManager indexModeProcessor) -
Method Summary
Modifier and TypeMethodDescriptionprotected static AttributeMappinggetIndexedAttribute(FeatureTypeMapping mapping, String xpath) Search for indexed attribute, including on Nested Featuresprotected IndexIdIteratorprotected List<PropertyName>Extracts next id list from index iteratorprotected voidInitialize the index FeatureCollection and iteratorprotected booleanprotected voidAnalyze query and select a plan: 1.- All fields indexed, execute all query on index layer 2.- Mixed fields indexed and not, execute indexed operators and re-map query to databaseprotected QueryConvert query to retrieve only id field, no other fieldsprotected FilterunrollFilter(Filter filter) static PropertyNameunrollIndex(PropertyName expression, FeatureTypeMapping mapping) protected QueryunrollIndexes(Query query) protected SortBy[]unrollSortBy(SortBy[] sortArray) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface FeatureIterator
close, hasNext, nextMethods inherited from interface Iterator
forEachRemaining, hasNext, next, remove
-
Field Details
-
ff
-
store
-
mapping
-
query
-
unrolledFilter
-
transaction
-
indexIterator
-
sourceIterator
-
indexModeProc
-
queryMode
-
-
Constructor Details
-
IndexedMappingFeatureIterator
public IndexedMappingFeatureIterator(AppSchemaDataAccess store, FeatureTypeMapping mapping, Query query, Filter unrolledFilter, Transaction transaction, IndexQueryManager indexModeProcessor)
-
-
Method Details
-
selectExecutionPlan
protected void selectExecutionPlan()Analyze query and select a plan: 1.- All fields indexed, execute all query on index layer 2.- Mixed fields indexed and not, execute indexed operators and re-map query to database -
unrollIndexes
-
unrollSortBy
-
unrollIndex
-
unrollFilter
-
getFidStepList
-
getFidAttrMap
-
getFidIndexName
-
isDenormalized
protected boolean isDenormalized() -
getIndexIterator
-
initializeIndexIterator
Initialize the index FeatureCollection and iterator- Throws:
IOException
-
transformQueryToIdsOnly
Convert query to retrieve only id field, no other fields- Returns:
- converted Query
-
getIndexQueryProperties
-
getNextSourceIdList
Extracts next id list from index iterator- Returns:
- list of id string
-
getIndexedAttribute
Search for indexed attribute, including on Nested Features- Returns:
- indexed attribute xpath, or null if not found
-