Package org.infinispan.query.core.impl
Class EmbeddedQuery<T>
java.lang.Object
org.infinispan.query.dsl.impl.BaseQuery<T>
org.infinispan.query.core.impl.BaseEmbeddedQuery<T>
org.infinispan.query.core.impl.EmbeddedQuery<T>
- All Implemented Interfaces:
Iterable<T>,org.infinispan.query.dsl.PaginationContext<org.infinispan.query.dsl.Query<T>>,org.infinispan.query.dsl.ParameterContext<org.infinispan.query.dsl.Query<T>>,org.infinispan.query.dsl.Query<T>
Non-indexed embedded-mode query.
- Since:
- 7.0
- Author:
- anistor@redhat.com
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class org.infinispan.query.core.impl.BaseEmbeddedQuery
cache, partitionHandlingSupport, queryStatistics, statementTypeFields inherited from class org.infinispan.query.dsl.impl.BaseQuery
hitCountAccuracy, local, maxResults, namedParameters, projection, queryFactory, queryString, startOffset, timeout -
Constructor Summary
ConstructorsConstructorDescriptionEmbeddedQuery(QueryEngine<?> queryEngine, org.infinispan.query.dsl.QueryFactory queryFactory, org.infinispan.AdvancedCache<?, ?> cache, String queryString, org.infinispan.objectfilter.impl.syntax.parser.IckleParsingResult.StatementType statementType, Map<String, Object> namedParameters, String[] projection, long startOffset, int maxResults, int defaultMaxResults, LocalQueryStatistics queryStatistics, boolean local) -
Method Summary
Modifier and TypeMethodDescriptionorg.infinispan.query.dsl.QueryResult<T>execute()intprotected Comparator<Comparable<?>[]>Create a comparator to be used for ordering the results returned byBaseEmbeddedQuery.getInternalIterator().protected org.infinispan.commons.util.CloseableIterator<org.infinispan.objectfilter.ObjectFilter.FilterResult>Create an iterator over the results of the query, in no particular order.protected voidrecordQuery(long time) voidtoString()Methods inherited from class org.infinispan.query.core.impl.BaseEmbeddedQuery
getResultSize, isSelectStatement, iterator, listMethods inherited from class org.infinispan.query.dsl.impl.BaseQuery
entryIterator, getMaxResults, getParameters, getProjection, getQueryString, getStartOffset, hasProjections, hitCountAccuracy, hitCountAccuracy, isLocal, local, maxResults, setParameter, setParameters, startOffset, timeout, validateNamedParametersMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
EmbeddedQuery
public EmbeddedQuery(QueryEngine<?> queryEngine, org.infinispan.query.dsl.QueryFactory queryFactory, org.infinispan.AdvancedCache<?, ?> cache, String queryString, org.infinispan.objectfilter.impl.syntax.parser.IckleParsingResult.StatementType statementType, Map<String, Object> namedParameters, String[] projection, long startOffset, int maxResults, int defaultMaxResults, LocalQueryStatistics queryStatistics, boolean local)
-
-
Method Details
-
resetQuery
public void resetQuery()- Overrides:
resetQueryin classBaseEmbeddedQuery<T>
-
recordQuery
protected void recordQuery(long time) - Specified by:
recordQueryin classBaseEmbeddedQuery<T>
-
getComparator
Description copied from class:BaseEmbeddedQueryCreate a comparator to be used for ordering the results returned byBaseEmbeddedQuery.getInternalIterator().- Specified by:
getComparatorin classBaseEmbeddedQuery<T>- Returns:
- the comparator or
nullif no sorting needs to be applied
-
getInternalIterator
protected org.infinispan.commons.util.CloseableIterator<org.infinispan.objectfilter.ObjectFilter.FilterResult> getInternalIterator()Description copied from class:BaseEmbeddedQueryCreate an iterator over the results of the query, in no particular order. Ordering will be provided ifBaseEmbeddedQuery.getComparator()returns a non-nullComparator. Please note this it not the same iterator as the one retuend byBaseEmbeddedQuery.iterator().- Specified by:
getInternalIteratorin classBaseEmbeddedQuery<T>
-
execute
- Specified by:
executein interfaceorg.infinispan.query.dsl.Query<T>- Overrides:
executein classBaseEmbeddedQuery<T>
-
executeStatement
public int executeStatement() -
toString
- Overrides:
toStringin classBaseEmbeddedQuery<T>
-