Package org.rumbledb.runtime.typing
Class InstanceOfIterator
java.lang.Object
org.rumbledb.runtime.plan.RuntimePlan<Item>
org.rumbledb.runtime.plan.ItemRuntimePlan
org.rumbledb.runtime.AbstractAtMostOneItemRuntimePlan
org.rumbledb.runtime.typing.InstanceOfIterator
- All Implemented Interfaces:
Serializable,AtMostOneLocalRuntimePlan<Item>,LocalRuntimePlan<Item>
- See Also:
-
Field Summary
Fields inherited from class org.rumbledb.runtime.plan.RuntimePlan
staticContext -
Constructor Summary
ConstructorsConstructorDescriptionInstanceOfIterator(ItemRuntimePlan child, SequenceType sequenceType, RuntimeStaticContext staticContext) -
Method Summary
Modifier and TypeMethodDescriptionstatic booleandoesItemTypeMatchItem(ItemType itemType, Item itemToMatch) Item type tests.evaluateAtMostOne(DynamicContext dynamicContext) Evaluates the plan without allocating a cursor.Methods inherited from class org.rumbledb.runtime.AbstractAtMostOneItemRuntimePlan
createNativeCursorMethods inherited from class org.rumbledb.runtime.plan.ItemRuntimePlan
getChild, getChildren, getStaticType, getVariableDependencies, isSparkJobNeeded, printMethods inherited from class org.rumbledb.runtime.plan.RuntimePlan
getConfiguration, getCursor, getDataFrame, getMetadata, getRDD, getRuntimeStaticContext, materialize, materializeAtMost, materializeAtMostOne, materializeExactlyOne, materializeFirstOrNull
-
Constructor Details
-
InstanceOfIterator
public InstanceOfIterator(ItemRuntimePlan child, SequenceType sequenceType, RuntimeStaticContext staticContext)
-
-
Method Details
-
evaluateAtMostOne
Description copied from interface:AtMostOneLocalRuntimePlanEvaluates the plan without allocating a cursor.- Specified by:
evaluateAtMostOnein interfaceAtMostOneLocalRuntimePlan<Item>- Specified by:
evaluateAtMostOnein classAbstractAtMostOneItemRuntimePlan- Parameters:
dynamicContext- the dynamic context for the evaluation- Returns:
- the value, or
nullfor the empty sequence
-
doesItemTypeMatchItem
Item type tests. This supersedes the method isTypeOf() formerly located in the Item interface, as part of the efforts to cleanly separate item storage from item manipulation (which is the domain of responsibility of runtime iterators).- Parameters:
itemType- the item type to match against the item.itemToMatch- the item to match against the type.- Returns:
- true if itemToMatch matches itemType.
-