Class FrozenElementsFinder
- java.lang.Object
-
- net.ssehub.easy.varModel.model.AbstractProjectVisitor
-
- net.ssehub.easy.varModel.model.filter.AbstractFrozenElementsFinder
-
- net.ssehub.easy.varModel.model.filter.FrozenElementsFinder
-
- All Implemented Interfaces:
ICustomDatatypeVisitor,IModelVisitor
public class FrozenElementsFinder extends AbstractFrozenElementsFinder
This class searches through a project (and its imports) for finding frozen elements.- Author:
- El-Sharkawy
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<IFreezable>frozenElementsprivate java.util.Map<IFreezable,FreezeBlock>frozenMap
-
Constructor Summary
Constructors Constructor Description FrozenElementsFinder(Project project, FilterType filtertype)Default constructor for this class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FreezeBlockgetFreezeBlock(IFreezable freezable)Returns the freeze block to the givenfreezable.java.util.List<IFreezable>getFrozenElements()Returns all discovered frozen elements.voidvisitCompoundAccessStatement(CompoundAccessStatement access)Visits a compound access statement (may occur in freeze blocks.voidvisitFreezeBlock(FreezeBlock freeze)Method for visiting a freeze block.-
Methods inherited from class net.ssehub.easy.varModel.model.filter.AbstractFrozenElementsFinder
visitAttribute, visitAttributeAssignment, visitComment, visitCompound, visitConstraint, visitDecisionVariableDeclaration, visitDerivedDatatype, visitEnum, visitEnumLiteral, visitOperationDefinition, visitOrderedEnum, visitPartialEvaluationBlock, visitProjectInterface, visitReference, visitSequence, visitSet
-
Methods inherited from class net.ssehub.easy.varModel.model.AbstractProjectVisitor
clear, getFilterType, getStartingProject, visitProject, visitProjectImport
-
-
-
-
Field Detail
-
frozenElements
private java.util.List<IFreezable> frozenElements
-
frozenMap
private java.util.Map<IFreezable,FreezeBlock> frozenMap
-
-
Constructor Detail
-
FrozenElementsFinder
public FrozenElementsFinder(Project project, FilterType filtertype)
Default constructor for this class.- Parameters:
project- The project which should be inspected.filtertype- Specifies whether imports shall be considered or not.
-
-
Method Detail
-
getFrozenElements
public java.util.List<IFreezable> getFrozenElements()
Returns all discovered frozen elements.- Returns:
- All frozen elements.
-
getFreezeBlock
public FreezeBlock getFreezeBlock(IFreezable freezable)
Returns the freeze block to the givenfreezable.- Parameters:
freezable- the freezable- Returns:
- the freeze block (if also in
getFrozenElements(), null else)
-
visitFreezeBlock
public void visitFreezeBlock(FreezeBlock freeze)
Description copied from interface:IModelVisitorMethod for visiting a freeze block.- Parameters:
freeze- The freeze block which should be visited.
-
visitCompoundAccessStatement
public void visitCompoundAccessStatement(CompoundAccessStatement access)
Description copied from interface:IModelVisitorVisits a compound access statement (may occur in freeze blocks.- Parameters:
access- the access statement
-
-