Interface RecordQueryPlan
-
- All Superinterfaces:
Bindable
,PlanHashable
,PlannerGraphRewritable
,QueryPlan<FDBQueriedRecord<Message>>
,RelationalExpression
- All Known Subinterfaces:
RecordQueryPlanWithChild
,RecordQueryPlanWithChildren
,RecordQueryPlanWithComparisons
,RecordQueryPlanWithIndex
,RecordQueryPlanWithNoChildren
- All Known Implementing Classes:
RecordQueryCoveringIndexPlan
,RecordQueryFilterPlan
,RecordQueryIndexPlan
,RecordQueryInJoinPlan
,RecordQueryInParameterJoinPlan
,RecordQueryIntersectionPlan
,RecordQueryInValuesJoinPlan
,RecordQueryLoadByKeysPlan
,RecordQueryPredicateFilterPlan
,RecordQueryScanPlan
,RecordQueryScoreForRankPlan
,RecordQueryTextIndexPlan
,RecordQueryTypeFilterPlan
,RecordQueryUnionPlan
,RecordQueryUnorderedDistinctPlan
,RecordQueryUnorderedPrimaryKeyDistinctPlan
,RecordQueryUnorderedUnionPlan
@API(STABLE) public interface RecordQueryPlan extends QueryPlan<FDBQueriedRecord<Message>>, PlannerGraphRewritable
An executable query plan for producing records. A query plan is run against a record store to produce a stream of matching records. A query plan of any complexity will have child plans and execute by altering or combining the children's streams in some way.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default <M extends Message>
RecordCursor<FDBQueriedRecord<M>>execute(FDBRecordStoreBase<M> store)
Execute this query plan.default <M extends Message>
RecordCursor<FDBQueriedRecord<M>>execute(FDBRecordStoreBase<M> store, EvaluationContext context)
Execute this query plan.<M extends Message>
RecordCursor<FDBQueriedRecord<M>>execute(FDBRecordStoreBase<M> store, EvaluationContext context, byte[] continuation, ExecuteProperties executeProperties)
Execute this query plan.default RecordCursor<FDBQueriedRecord<Message>>
execute(FDBRecordStore store, EvaluationContext context, byte[] continuation, ExecuteProperties executeProperties)
Execute this query plan.List<RecordQueryPlan>
getChildren()
Returns the (zero or more)RecordQueryPlan
children of this plan.default List<? extends QueryPlan<?>>
getQueryPlanChildren()
Returns the (zero or more) childQueryPlan
s of this plan.-
Methods inherited from interface com.apple.foundationdb.record.PlanHashable
planHash
-
Methods inherited from interface com.apple.foundationdb.record.query.plan.temp.explain.PlannerGraphRewritable
rewritePlannerGraph
-
Methods inherited from interface com.apple.foundationdb.record.query.plan.plans.QueryPlan
execute, execute, getComplexity, getUsedIndexes, hasFullRecordScan, hasIndexScan, hasLoadBykeys, hasRecordScan, isReverse, logPlanStructure
-
Methods inherited from interface com.apple.foundationdb.record.query.plan.temp.RelationalExpression
acceptPropertyVisitor, bindTo, equalsWithoutChildren, getQuantifiers, show
-
-
-
-
Method Detail
-
execute
@Nonnull <M extends Message> RecordCursor<FDBQueriedRecord<M>> execute(@Nonnull FDBRecordStoreBase<M> store, @Nonnull EvaluationContext context, @Nullable byte[] continuation, @Nonnull ExecuteProperties executeProperties)
Execute this query plan.- Type Parameters:
M
- type used to represent stored records- Parameters:
store
- record store from which to fetch recordscontext
- evaluation context containing parameter bindingscontinuation
- continuation from a previous execution of this same planexecuteProperties
- limits on execution- Returns:
- a cursor of records that match the query criteria
-
execute
@Nonnull default RecordCursor<FDBQueriedRecord<Message>> execute(@Nonnull FDBRecordStore store, @Nonnull EvaluationContext context, @Nullable byte[] continuation, @Nonnull ExecuteProperties executeProperties)
Description copied from interface:QueryPlan
Execute this query plan.- Specified by:
execute
in interfaceQueryPlan<FDBQueriedRecord<Message>>
- Parameters:
store
- record store from which to fetch itemscontext
- evaluation context containing parameter bindingscontinuation
- continuation from a previous execution of this same planexecuteProperties
- limits on execution- Returns:
- a cursor of items that match the query criteria
-
execute
@Nonnull default <M extends Message> RecordCursor<FDBQueriedRecord<M>> execute(@Nonnull FDBRecordStoreBase<M> store)
Execute this query plan.- Type Parameters:
M
- type used to represent stored records- Parameters:
store
- record store from which to fetch records- Returns:
- a cursor of records that match the query criteria
-
execute
@Nonnull default <M extends Message> RecordCursor<FDBQueriedRecord<M>> execute(@Nonnull FDBRecordStoreBase<M> store, @Nonnull EvaluationContext context)
Execute this query plan.- Type Parameters:
M
- type used to represent stored records- Parameters:
store
- record store to accesscontext
- evaluation context containing parameter bindings- Returns:
- a cursor of records that match the query criteria
-
getChildren
@API(UNSTABLE) @Nonnull List<RecordQueryPlan> getChildren()
Returns the (zero or more)RecordQueryPlan
children of this plan.Warning: This part of the API is undergoing active development. At some point in the future, the return type of this method will change to allow it to return a list of generic
QueryPlan
s. At current, everyRecordQueryPlan
can only have otherRecordQueryPlan
s as children. However, this is not guaranteed to be the case in the future. This method has been marked asAPI.Status.UNSTABLE
as of version 2.5.- Returns:
- the child plans
-
getQueryPlanChildren
@Nonnull default List<? extends QueryPlan<?>> getQueryPlanChildren()
Description copied from interface:QueryPlan
Returns the (zero or more) childQueryPlan
s of this plan. These children may or may not return elements of the same type as their parent plan.Warning: This part of the API is currently undergoing active development. At some point in the future, this will be renamed
getChildren()
. This cannot be done at current, however, as it would require an incompatible change togetChildren()
. That method has been markedAPI.Status.UNSTABLE
as of version 2.5.- Specified by:
getQueryPlanChildren
in interfaceQueryPlan<FDBQueriedRecord<Message>>
- Returns:
- the child plans of this plan
-
-