public abstract class AbstractOperationCompiler extends java.lang.Object implements IOperationCompiler
Modifier and Type | Field and Description |
---|---|
protected java.util.Set<CallWithAdornment> |
dependencies |
protected java.util.List<ISearchOperation> |
operations |
protected IQueryRuntimeContext |
runtimeContext |
protected static java.lang.String |
UNSUPPORTED_TYPE_MESSAGE |
protected java.util.Map<PConstraint,java.util.Set<java.lang.Integer>> |
variableBindings |
Constructor and Description |
---|
AbstractOperationCompiler(IQueryRuntimeContext runtimeContext) |
Modifier and Type | Method and Description |
---|---|
java.util.List<ISearchOperation> |
compile(SubPlan plan,
java.util.Set<PParameter> boundParameters)
Compiles a plan of
POperation s to a list of type List<ISearchOperation> |
protected void |
createCheck(AggregatorConstraint aggregator,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(BinaryReflexiveTransitiveClosure binaryTransitiveClosure,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(BinaryTransitiveClosure binaryTransitiveClosure,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(ConstantValue constant,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(ExpressionEvaluation expressionEvaluation,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(Inequality inequality,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(NegativePatternCall negativePatternCall,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(PatternMatchCounter counter,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createCheck(PositivePatternCall pCall,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected abstract void |
createCheck(TypeConstraint typeConstraint,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected abstract void |
createCheck(TypeFilterConstraint typeConstraint,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(AggregatorConstraint aggregator,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(BinaryReflexiveTransitiveClosure binaryTransitiveClosure,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(BinaryTransitiveClosure binaryTransitiveClosure,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(ConstantValue constant,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(ExpressionEvaluation expressionEvaluation,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(PatternMatchCounter patternMatchCounter,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtend(PositivePatternCall pCall,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected abstract void |
createExtend(TypeConstraint typeConstraint,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected void |
createExtendDispatcher(PConstraint pConstraint,
java.util.Map<PVariable,java.lang.Integer> variableMapping) |
protected abstract void |
createUnaryTypeCheck(IInputKey type,
int position) |
java.util.Set<CallWithAdornment> |
getDependencies()
Replaces previous method returning
MatcherReference |
java.util.Map<PVariable,java.lang.Integer> |
getVariableMappings() |
protected static final java.lang.String UNSUPPORTED_TYPE_MESSAGE
protected java.util.List<ISearchOperation> operations
protected java.util.Set<CallWithAdornment> dependencies
protected java.util.Map<PConstraint,java.util.Set<java.lang.Integer>> variableBindings
protected final IQueryRuntimeContext runtimeContext
public AbstractOperationCompiler(IQueryRuntimeContext runtimeContext)
protected abstract void createExtend(TypeConstraint typeConstraint, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected abstract void createCheck(TypeConstraint typeConstraint, java.util.Map<PVariable,java.lang.Integer> variableMapping)
ViatraQueryRuntimeException
protected abstract void createCheck(TypeFilterConstraint typeConstraint, java.util.Map<PVariable,java.lang.Integer> variableMapping)
ViatraQueryRuntimeException
protected abstract void createUnaryTypeCheck(IInputKey type, int position)
ViatraQueryRuntimeException
public java.util.List<ISearchOperation> compile(SubPlan plan, java.util.Set<PParameter> boundParameters)
POperation
s to a list of type List<ISearchOperation>
compile
in interface IOperationCompiler
plan
- boundParameters
- ViatraQueryRuntimeException
protected void createExtendDispatcher(PConstraint pConstraint, java.util.Map<PVariable,java.lang.Integer> variableMapping)
public java.util.Set<CallWithAdornment> getDependencies()
IOperationCompiler
MatcherReference
getDependencies
in interface IOperationCompiler
public java.util.Map<PVariable,java.lang.Integer> getVariableMappings()
getVariableMappings
in interface IOperationCompiler
protected void createCheck(PatternMatchCounter counter, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(PositivePatternCall pCall, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(ConstantValue constant, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(BinaryTransitiveClosure binaryTransitiveClosure, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(BinaryReflexiveTransitiveClosure binaryTransitiveClosure, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(ExpressionEvaluation expressionEvaluation, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(AggregatorConstraint aggregator, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(NegativePatternCall negativePatternCall, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createCheck(Inequality inequality, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(PositivePatternCall pCall, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(BinaryTransitiveClosure binaryTransitiveClosure, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(BinaryReflexiveTransitiveClosure binaryTransitiveClosure, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(ConstantValue constant, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(ExpressionEvaluation expressionEvaluation, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(AggregatorConstraint aggregator, java.util.Map<PVariable,java.lang.Integer> variableMapping)
protected void createExtend(PatternMatchCounter patternMatchCounter, java.util.Map<PVariable,java.lang.Integer> variableMapping)