Class SwitchStatement
- java.lang.Object
-
- org.benf.cfr.reader.bytecode.analysis.parse.statement.AbstractStatement
-
- org.benf.cfr.reader.bytecode.analysis.parse.statement.SwitchStatement
-
- All Implemented Interfaces:
HasByteCodeLoc,DeepCloneable<Statement>,Statement,ComparableUnderEC,Dumpable
public class SwitchStatement extends AbstractStatement
-
-
Field Summary
Fields Modifier and Type Field Description private booleansafeExpressionprivate BlockIdentifierswitchBlockprivate ExpressionswitchOn
-
Constructor Summary
Constructors Constructor Description SwitchStatement(BytecodeLoc loc, Expression switchOn, BlockIdentifier switchBlock)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcollectLValueUsage(LValueUsageCollector lValueUsageCollector)StatementdeepClone(CloneHelper cloneHelper)Dumperdump(Dumper dumper)booleanequivalentUnder(java.lang.Object o, EquivalenceConstraint constraint)booleanfallsToNext()BytecodeLocgetCombinedLoc()StructuredStatementgetStructuredStatement()BlockIdentifiergetSwitchBlock()ExpressiongetSwitchOn()voidreplaceSingleUsageLValues(LValueRewriter lValueRewriter, SSAIdentifiers ssaIdentifiers)voidrewriteExpressions(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers)voidsetLifetimeHint(LValue lv, boolean usedInChildren)voidsetSwitchOn(Expression switchOn)java.util.Set<LValue>wantsLifetimeHint()-
Methods inherited from class org.benf.cfr.reader.bytecode.analysis.parse.statement.AbstractStatement
addLoc, canThrow, collectLocallyMutatedVariables, collectLValueAssignments, collectObjectCreation, doesBlackListLValueReplacement, getCompoundParts, getContainer, getCreatedLValue, getLoc, getRValue, getTargetStatement, isCompound, outerDeepClone, setContainer, toString
-
-
-
-
Field Detail
-
switchOn
private Expression switchOn
-
switchBlock
private final BlockIdentifier switchBlock
-
safeExpression
private boolean safeExpression
-
-
Constructor Detail
-
SwitchStatement
SwitchStatement(BytecodeLoc loc, Expression switchOn, BlockIdentifier switchBlock)
-
-
Method Detail
-
getCombinedLoc
public BytecodeLoc getCombinedLoc()
-
deepClone
public Statement deepClone(CloneHelper cloneHelper)
-
replaceSingleUsageLValues
public void replaceSingleUsageLValues(LValueRewriter lValueRewriter, SSAIdentifiers ssaIdentifiers)
-
rewriteExpressions
public void rewriteExpressions(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers)
-
collectLValueUsage
public void collectLValueUsage(LValueUsageCollector lValueUsageCollector)
-
getStructuredStatement
public StructuredStatement getStructuredStatement()
-
getSwitchOn
public Expression getSwitchOn()
-
setSwitchOn
public void setSwitchOn(Expression switchOn)
-
getSwitchBlock
public BlockIdentifier getSwitchBlock()
-
equivalentUnder
public final boolean equivalentUnder(java.lang.Object o, EquivalenceConstraint constraint)
-
fallsToNext
public boolean fallsToNext()
- Specified by:
fallsToNextin interfaceStatement- Overrides:
fallsToNextin classAbstractStatement
-
wantsLifetimeHint
public java.util.Set<LValue> wantsLifetimeHint()
- Specified by:
wantsLifetimeHintin interfaceStatement- Overrides:
wantsLifetimeHintin classAbstractStatement
-
setLifetimeHint
public void setLifetimeHint(LValue lv, boolean usedInChildren)
- Specified by:
setLifetimeHintin interfaceStatement- Overrides:
setLifetimeHintin classAbstractStatement
-
-