public class VariablesInNotSimpleAssignmentConstraintsFinder
extends java.lang.Object
implements net.ssehub.easy.varModel.cst.IConstraintTreeVisitor
| Modifier and Type | Field and Description |
|---|---|
private boolean |
add |
private net.ssehub.easy.varModel.model.Constraint |
constraint |
private VariablesMap |
constraintMap |
private net.ssehub.easy.varModel.cstEvaluation.EvaluationVisitor |
evaluator |
| Constructor and Description |
|---|
VariablesInNotSimpleAssignmentConstraintsFinder(VariablesMap constraintMap)
Creates a visitor instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
accept(net.ssehub.easy.varModel.model.Constraint constraint,
net.ssehub.easy.varModel.confModel.Configuration config)
Accepts and visits a constraint.
|
void |
acceptAndClear(net.ssehub.easy.varModel.model.Constraint constraint,
net.ssehub.easy.varModel.confModel.Configuration config)
Combines
#accept(Constraint) and clear(). |
void |
acceptAndClear(net.ssehub.easy.varModel.model.Constraint constraint,
net.ssehub.easy.varModel.confModel.Configuration config,
boolean add)
Combines
#accept(Constraint) and clear(). |
void |
acceptAndClear(java.lang.Iterable<net.ssehub.easy.varModel.model.Constraint> constraints,
net.ssehub.easy.varModel.confModel.Configuration config,
boolean add)
Combines
#accept(Constraint) and clear() for an iterable of constraints. |
void |
clear()
Clears this visitor for reuse.
|
VariablesInNotSimpleAssignmentConstraintsFinder |
forRemove()
Turns this finder into remove mode.
|
private boolean |
isConstraint(net.ssehub.easy.varModel.cst.ConstraintSyntaxTree cst)
Returns whether the type of
cst is a constraint type. |
private void |
modifyRelation(net.ssehub.easy.varModel.model.AbstractVariable variable,
net.ssehub.easy.varModel.model.Constraint constraint)
|
void |
visitAnnotationVariable(net.ssehub.easy.varModel.cst.AttributeVariable variable) |
void |
visitBlockExpression(net.ssehub.easy.varModel.cst.BlockExpression block) |
void |
visitComment(net.ssehub.easy.varModel.cst.Comment comment) |
void |
visitCompoundAccess(net.ssehub.easy.varModel.cst.CompoundAccess access) |
void |
visitCompoundInitializer(net.ssehub.easy.varModel.cst.CompoundInitializer initializer) |
void |
visitConstantValue(net.ssehub.easy.varModel.cst.ConstantValue value) |
void |
visitContainerInitializer(net.ssehub.easy.varModel.cst.ContainerInitializer initializer) |
void |
visitContainerOperationCall(net.ssehub.easy.varModel.cst.ContainerOperationCall call) |
void |
visitIfThen(net.ssehub.easy.varModel.cst.IfThen ifThen) |
void |
visitLet(net.ssehub.easy.varModel.cst.Let let) |
void |
visitMultiAndExpression(net.ssehub.easy.varModel.cst.MultiAndExpression expression) |
void |
visitOclFeatureCall(net.ssehub.easy.varModel.cst.OCLFeatureCall call) |
void |
visitParenthesis(net.ssehub.easy.varModel.cst.Parenthesis parenthesis) |
void |
visitSelf(net.ssehub.easy.varModel.cst.Self self) |
void |
visitUnresolvedExpression(net.ssehub.easy.varModel.cst.UnresolvedExpression expression) |
void |
visitVariable(net.ssehub.easy.varModel.cst.Variable variable) |
private VariablesMap constraintMap
private net.ssehub.easy.varModel.model.Constraint constraint
private boolean add
private net.ssehub.easy.varModel.cstEvaluation.EvaluationVisitor evaluator
public VariablesInNotSimpleAssignmentConstraintsFinder(VariablesMap constraintMap)
constraintMap - the constraint map to use for storing resultspublic void accept(net.ssehub.easy.varModel.model.Constraint constraint,
net.ssehub.easy.varModel.confModel.Configuration config)
constraint - the constraint to acceptconfig - the configuration used to resolve expressionspublic void acceptAndClear(net.ssehub.easy.varModel.model.Constraint constraint,
net.ssehub.easy.varModel.confModel.Configuration config)
#accept(Constraint) and clear().constraint - the constraint to acceptconfig - the configuration used to resolve expressionspublic void acceptAndClear(net.ssehub.easy.varModel.model.Constraint constraint,
net.ssehub.easy.varModel.confModel.Configuration config,
boolean add)
#accept(Constraint) and clear().constraint - the constraint to acceptconfig - the configuration used to resolve expressionsadd - add true or remove falsepublic void acceptAndClear(java.lang.Iterable<net.ssehub.easy.varModel.model.Constraint> constraints,
net.ssehub.easy.varModel.confModel.Configuration config,
boolean add)
#accept(Constraint) and clear() for an iterable of constraints.constraints - the constraints to acceptconfig - the configuration used to resolve expressionsadd - add true or remove falsepublic void clear()
public VariablesInNotSimpleAssignmentConstraintsFinder forRemove()
public void visitConstantValue(net.ssehub.easy.varModel.cst.ConstantValue value)
visitConstantValue in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitVariable(net.ssehub.easy.varModel.cst.Variable variable)
visitVariable in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorprivate void modifyRelation(net.ssehub.easy.varModel.model.AbstractVariable variable,
net.ssehub.easy.varModel.model.Constraint constraint)
variable - the variableconstraint - the constraintpublic void visitAnnotationVariable(net.ssehub.easy.varModel.cst.AttributeVariable variable)
visitAnnotationVariable in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitParenthesis(net.ssehub.easy.varModel.cst.Parenthesis parenthesis)
visitParenthesis in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitComment(net.ssehub.easy.varModel.cst.Comment comment)
visitComment in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorprivate boolean isConstraint(net.ssehub.easy.varModel.cst.ConstraintSyntaxTree cst)
cst is a constraint type.cst - the constraint syntax tree to look fortrue for constraint type, false elsepublic void visitOclFeatureCall(net.ssehub.easy.varModel.cst.OCLFeatureCall call)
visitOclFeatureCall in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitMultiAndExpression(net.ssehub.easy.varModel.cst.MultiAndExpression expression)
visitMultiAndExpression in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitLet(net.ssehub.easy.varModel.cst.Let let)
visitLet in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitIfThen(net.ssehub.easy.varModel.cst.IfThen ifThen)
visitIfThen in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitContainerOperationCall(net.ssehub.easy.varModel.cst.ContainerOperationCall call)
visitContainerOperationCall in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitCompoundAccess(net.ssehub.easy.varModel.cst.CompoundAccess access)
visitCompoundAccess in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitUnresolvedExpression(net.ssehub.easy.varModel.cst.UnresolvedExpression expression)
visitUnresolvedExpression in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitCompoundInitializer(net.ssehub.easy.varModel.cst.CompoundInitializer initializer)
visitCompoundInitializer in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitContainerInitializer(net.ssehub.easy.varModel.cst.ContainerInitializer initializer)
visitContainerInitializer in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitSelf(net.ssehub.easy.varModel.cst.Self self)
visitSelf in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorpublic void visitBlockExpression(net.ssehub.easy.varModel.cst.BlockExpression block)
visitBlockExpression in interface net.ssehub.easy.varModel.cst.IConstraintTreeVisitorCopyright © 2009 - 2018 SSE. All Rights Reserved.