| Modifier and Type | Class and Description |
|---|---|
| private static class | |
| public static interface | |
| private static enum |
| Modifier and Type | Field and Description |
|---|---|
| private final Deque | |
| private final FinalVariableAnalyzer. | |
| private Set | |
| private boolean | |
| private boolean | |
| private final SourceUnit |
| Access | Constructor and Description |
|---|---|
| public | |
| public | FinalVariableAnalyzer(final SourceUnit sourceUnit, final FinalVariableAnalyzer.
|
| assignmentTracker | back to summary |
|---|---|
| private final Deque<Map<Variable, FinalVariableAnalyzer. | |
| callback | back to summary |
|---|---|
| private final FinalVariableAnalyzer. | |
| declaredFinalVariables | back to summary |
|---|---|
| private Set<Variable> declaredFinalVariables | |
| inArgumentList | back to summary |
|---|---|
| private boolean inArgumentList | |
| inAssignmentRHS | back to summary |
|---|---|
| private boolean inAssignmentRHS | |
| sourceUnit | back to summary |
|---|---|
| private final SourceUnit sourceUnit | |
| FinalVariableAnalyzer | back to summary |
|---|---|
| public FinalVariableAnalyzer(final SourceUnit sourceUnit) | |
| FinalVariableAnalyzer | back to summary |
|---|---|
| public FinalVariableAnalyzer(final SourceUnit sourceUnit, final FinalVariableAnalyzer. | |
| checkPrePostfixOperation | back to summary |
|---|---|
| private void checkPrePostfixOperation(final Expression variable, final Expression originalExpression) | |
| cleanLocalVars | back to summary |
|---|---|
| private void cleanLocalVars(Map<Variable, FinalVariableAnalyzer. | |
| fallsThrough | back to summary |
|---|---|
private boolean fallsThrough(Statement statement)
| |
| fixVar | back to summary |
|---|---|
| private void fixVar(Variable var) | |
| getSourceUnit | back to summary |
|---|---|
| protected SourceUnit getSourceUnit() Implements abstract org.
| |
| getState | back to summary |
|---|---|
| private Map | |
| getTarget | back to summary |
|---|---|
| private static Variable getTarget(Variable v) | |
| isEffectivelyFinal | back to summary |
|---|---|
| public boolean isEffectivelyFinal(Variable v) | |
| popState | back to summary |
|---|---|
| private Map | |
| pushState | back to summary |
|---|---|
| private Map | |
| recordAssignment | back to summary |
|---|---|
| private void recordAssignment(Variable var, boolean isDeclaration, boolean uninitialized, boolean forceVariable, Expression expression) | |
| recordAssignments | back to summary |
|---|---|
| private void recordAssignments(BinaryExpression expression, boolean isDeclaration, Expression leftExpression, Expression rightExpression) | |
| recordFinalVars | back to summary |
|---|---|
| private void recordFinalVars(Expression leftExpression) | |
| returningBlock | back to summary |
|---|---|
private boolean returningBlock(Statement block)
| |
| visitArgumentlistExpression | back to summary |
|---|---|
| public void visitArgumentlistExpression(ArgumentListExpression ale) Overrides org. Implements org.
| |
| visitBinaryExpression | back to summary |
|---|---|
| public void visitBinaryExpression(final BinaryExpression expression) Overrides org. Implements org.
| |
| visitBlockStatement | back to summary |
|---|---|
| public void visitBlockStatement(final BlockStatement block) Overrides org. Implements org.
| |
| visitCatchFinally | back to summary |
|---|---|
| private void visitCatchFinally(Map<Variable, FinalVariableAnalyzer. | |
| visitClosureExpression | back to summary |
|---|---|
| public void visitClosureExpression(final ClosureExpression expression) Overrides org. Implements org.
| |
| visitIfElse | back to summary |
|---|---|
| public void visitIfElse(final IfStatement ifElse) Overrides org. Implements org.
| |
| visitPostfixExpression | back to summary |
|---|---|
| public void visitPostfixExpression(final PostfixExpression expression) Overrides org. Implements org.
| |
| visitPrefixExpression | back to summary |
|---|---|
| public void visitPrefixExpression(final PrefixExpression expression) Overrides org. Implements org.
| |
| visitSwitch | back to summary |
|---|---|
| public void visitSwitch(SwitchStatement switchS) Overrides org. Implements org.
| |
| visitTryCatchFinally | back to summary |
|---|---|
| public void visitTryCatchFinally(final TryCatchStatement statement) Overrides org. Implements org.
| |
| visitVariableExpression | back to summary |
|---|---|
| public void visitVariableExpression(final VariableExpression expression) Overrides org. Implements org.
| |
| Modifier and Type | Field and Description |
|---|---|
| private static final long |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public FinalVariableAnalyzer. | get(final Object
the key whose associated value is to be returned key)Overrides java. Implements java. null if this map contains no mapping for the key.
|
| public FinalVariableAnalyzer. | put(final Variable
key with which the specified value is to be associated key, final FinalVariableAnalyzer.value to be associated with the specified key valueOverrides java. Implements java. |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID | |
| StateMap | back to summary |
|---|---|
| private StateMap() | |
| get | back to summary |
|---|---|
| public FinalVariableAnalyzer. Overrides java. Implements java. Doc from java. Returns the value to which the specified key is mapped,
or More formally, if this map contains a mapping from a key
A return value of
| |
| put | back to summary |
|---|---|
| public FinalVariableAnalyzer. Overrides java. Implements java. Doc from java. Associates the specified value with the specified key in this map. If the map previously contained a mapping for the key, the old value is replaced.
| |
| Modifier and Type | Method and Description |
|---|---|
| public void | variableNotAlwaysInitialized(VariableExpression
the variable detected as potentially uninitialized var)Callback used whenever a variable is declared as final, but can remain in an uninitialized state |
| public void | variableNotFinal(Variable
the variable detected as not final var, Expression the expression responsible for the contract to be broken bexp)Callback called whenever an assignment transforms an effectively final variable into a non final variable (aka, breaks the "final" modifier contract) |
| variableNotAlwaysInitialized | back to summary |
|---|---|
| public void variableNotAlwaysInitialized(VariableExpression var) Callback used whenever a variable is declared as final, but can remain in an uninitialized state
| |
| variableNotFinal | back to summary |
|---|---|
| public void variableNotFinal(Variable var, Expression bexp) Callback called whenever an assignment transforms an effectively final variable into a non final variable (aka, breaks the "final" modifier contract)
| |
| Modifier and Type | Field and Description |
|---|---|
| public static final FinalVariableAnalyzer. | |
| public static final FinalVariableAnalyzer. | |
| public static final FinalVariableAnalyzer. | |
| public static final FinalVariableAnalyzer. | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public FinalVariableAnalyzer. | |
| public boolean | |
| public static FinalVariableAnalyzer. | |
| public static FinalVariableAnalyzer. |
| is_ambiguous | back to summary |
|---|---|
| public static final FinalVariableAnalyzer. | |
| is_final | back to summary |
|---|---|
| public static final FinalVariableAnalyzer. | |
| is_uninitialized | back to summary |
|---|---|
| public static final FinalVariableAnalyzer. | |
| is_var | back to summary |
|---|---|
| public static final FinalVariableAnalyzer. | |
| isFinal | back to summary |
|---|---|
| private final boolean isFinal | |
| VariableState | back to summary |
|---|---|
| private VariableState(final boolean isFinal) | |
| getNext | back to summary |
|---|---|
| public FinalVariableAnalyzer. | |
| isFinal | back to summary |
|---|---|
| public boolean isFinal() | |
| valueOf | back to summary |
|---|---|
| public static FinalVariableAnalyzer. | |
| values | back to summary |
|---|---|
| public static FinalVariableAnalyzer. | |