Class AbstractConstraintProcessor
java.lang.Object
net.ssehub.easy.reasoning.sseReasoner.functions.AbstractConstraintProcessor
- Direct Known Subclasses:
Resolver.OtherConstraintsProcessor
Interface for a generic constraint processor functor (avoid collections, process directly).
- Author:
- Holger Eichelberger
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumExpression types. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract ContextStackReturns the context stack, e.g., for type exclusions.abstract net.ssehub.easy.varModel.cst.ConstraintSyntaxTreeprocess(net.ssehub.easy.varModel.cst.ConstraintSyntaxTree cst, AbstractConstraintProcessor.ExpressionType type, String slot, net.ssehub.easy.varModel.model.IModelElement parent) Processes a constraint syntax tree.net.ssehub.easy.varModel.cst.ConstraintSyntaxTreeprocess(net.ssehub.easy.varModel.model.Constraint constraint, AbstractConstraintProcessor.ExpressionType type) Processes a constraint (taking over the parent ofconstraint).
-
Constructor Details
-
AbstractConstraintProcessor
public AbstractConstraintProcessor()
-
-
Method Details
-
process
public abstract net.ssehub.easy.varModel.cst.ConstraintSyntaxTree process(net.ssehub.easy.varModel.cst.ConstraintSyntaxTree cst, AbstractConstraintProcessor.ExpressionType type, String slot, net.ssehub.easy.varModel.model.IModelElement parent) Processes a constraint syntax tree.- Parameters:
cst- the constraint syntax treetype- the type ofcstslot- the slot name, only in case ofAbstractConstraintProcessor.ExpressionType.DEFAULTorAbstractConstraintProcessor.ExpressionType.ANNOTATION_DEFAULTparent- the actual/intended parent if not determined otherwise- Returns:
- the processed constraint syntax tree, may be
cst
-
process
public net.ssehub.easy.varModel.cst.ConstraintSyntaxTree process(net.ssehub.easy.varModel.model.Constraint constraint, AbstractConstraintProcessor.ExpressionType type) Processes a constraint (taking over the parent ofconstraint). [convenience]- Parameters:
constraint- the constraint to be processedtype- the type of the constraint- Returns:
- the processed constraint syntax tree, may be the one of
constraint
-
getContextStack
Returns the context stack, e.g., for type exclusions.- Returns:
- the context stack
-