public class ProgramVariableCollector extends JavaASTVisitor
| Modifier and Type | Field and Description |
|---|---|
private LinkedHashSet<LocationVariable> |
result |
services| Constructor and Description |
|---|
ProgramVariableCollector(ProgramElement root,
Services services)
collects all program variables occuring in the AST root
using this constructor is equivalent to ProggramVariableCollector(root, false)
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
collectHeapVariables() |
protected void |
doDefaultAction(SourceElement x)
the action that is performed just before leaving the node the
last time
|
void |
performActionOnBlockContract(BlockContract x) |
void |
performActionOnLocationVariable(LocationVariable x) |
void |
performActionOnLoopInvariant(LoopInvariant x) |
LinkedHashSet<LocationVariable> |
result() |
void |
start()
starts the walker
|
String |
toString() |
doAction, performActionOnAbstractProgramElement, performActionOnAllFields, performActionOnAllObjects, performActionOnArrayDeclaration, performActionOnArrayInitializer, performActionOnArrayLengthReference, performActionOnArrayReference, performActionOnAssert, performActionOnBinaryAnd, performActionOnBinaryAndAssignment, performActionOnBinaryNot, performActionOnBinaryOr, performActionOnBinaryOrAssignment, performActionOnBinaryXOr, performActionOnBinaryXOrAssignment, performActionOnBooleanLiteral, performActionOnBreak, performActionOnCase, performActionOnCatch, performActionOnCatchAllStatement, performActionOnCharLiteral, performActionOnClassDeclaration, performActionOnClassInitializer, performActionOnComment, performActionOnCompilationUnit, performActionOnConditional, performActionOnConstructorDeclaration, performActionOnContextStatementBlock, performActionOnContinue, performActionOnCopyAssignment, performActionOnDefault, performActionOnDivide, performActionOnDivideAssignment, performActionOnDLEmbeddedExpression, performActionOnDo, performActionOnDoubleLiteral, performActionOnElse, performActionOnEmptyMapLiteral, performActionOnEmptySeqLiteral, performActionOnEmptySetLiteral, performActionOnEmptyStatement, performActionOnEnhancedFor, performActionOnEquals, performActionOnExactInstanceof, performActionOnExecutionContext, performActionOnExtends, performActionOnFieldDeclaration, performActionOnFieldReference, performActionOnFieldSpecification, performActionOnFinally, performActionOnFloatLiteral, performActionOnFor, performActionOnForUpdates, performActionOnGreaterOrEquals, performActionOnGreaterThan, performActionOnGuard, performActionOnIf, performActionOnImplements, performActionOnImplicitFieldSpecification, performActionOnImport, performActionOnInstanceof, performActionOnInterfaceDeclaration, performActionOnIntersect, performActionOnIntLiteral, performActionOnIProgramVariable, performActionOnLabeledStatement, performActionOnLessOrEquals, performActionOnLessThan, performActionOnLocalVariableDeclaration, performActionOnLogicalAnd, performActionOnLogicalNot, performActionOnLogicalOr, performActionOnLongLiteral, performActionOnLoopInit, performActionOnMetaClassReference, performActionOnMethod, performActionOnMethodBodyStatement, performActionOnMethodDeclaration, performActionOnMethodFrame, performActionOnMethodReference, performActionOnMinus, performActionOnMinusAssignment, performActionOnModifier, performActionOnModulo, performActionOnModuloAssignment, performActionOnNegative, performActionOnNew, performActionOnNewArray, performActionOnNotEquals, performActionOnNullLiteral, performActionOnPackageReference, performActionOnPackageSpecification, performActionOnParameterDeclaration, performActionOnParenthesizedExpression, performActionOnPassiveExpression, performActionOnPlus, performActionOnPlusAssignment, performActionOnPositive, performActionOnPostDecrement, performActionOnPostIncrement, performActionOnPreDecrement, performActionOnPreIncrement, performActionOnProgramConstant, performActionOnProgramElementName, performActionOnProgramMetaConstruct, performActionOnProgramMethod, performActionOnProgramVariable, performActionOnReturn, performActionOnSchematicFieldReference, performActionOnSchemaVariable, performActionOnSeqConcat, performActionOnSeqGet, performActionOnSeqIndexOf, performActionOnSeqLength, performActionOnSeqReverse, performActionOnSeqSingleton, performActionOnSeqSub, performActionOnSetMinus, performActionOnSetUnion, performActionOnShiftLeft, performActionOnShiftLeftAssignment, performActionOnShiftRight, performActionOnShiftRightAssignment, performActionOnSingleton, performActionOnStatementBlock, performActionOnStringLiteral, performActionOnSuperArrayDeclaration, performActionOnSuperConstructorReference, performActionOnSuperReference, performActionOnSwitch, performActionOnSynchronizedBlock, performActionOnThen, performActionOnThisConstructorReference, performActionOnThisReference, performActionOnThrow, performActionOnThrows, performActionOnTimes, performActionOnTimesAssignment, performActionOnTransactionStatement, performActionOnTry, performActionOnTypeCast, performActionOnTypeReference, performActionOnUnsignedShiftRight, performActionOnUnsignedShiftRightAssignment, performActionOnVariableDeclaration, performActionOnVariableReference, performActionOnVariableSpecification, performActionOnWhile, walkdepth, rootprivate final LinkedHashSet<LocationVariable> result
public ProgramVariableCollector(ProgramElement root, Services services)
root - the ProgramElement which is the root of the ASTservices - the Services objectprotected void collectHeapVariables()
public void start()
JavaASTWalkerstart in class JavaASTWalkerpublic LinkedHashSet<LocationVariable> result()
protected void doDefaultAction(SourceElement x)
JavaASTVisitordoDefaultAction in class JavaASTVisitorpublic void performActionOnLocationVariable(LocationVariable x)
performActionOnLocationVariable in interface VisitorperformActionOnLocationVariable in class JavaASTVisitorpublic void performActionOnLoopInvariant(LoopInvariant x)
performActionOnLoopInvariant in interface VisitorperformActionOnLoopInvariant in class JavaASTVisitorpublic void performActionOnBlockContract(BlockContract x)
performActionOnBlockContract in interface VisitorperformActionOnBlockContract in class JavaASTVisitor