Class CaseStatement
- java.lang.Object
-
- org.benf.cfr.reader.bytecode.analysis.parse.statement.AbstractStatement
-
- org.benf.cfr.reader.bytecode.analysis.parse.statement.CaseStatement
-
- All Implemented Interfaces:
HasByteCodeLoc
,DeepCloneable<Statement>
,Statement
,ComparableUnderEC
,Dumpable
public class CaseStatement extends AbstractStatement
-
-
Field Summary
Fields Modifier and Type Field Description private BlockIdentifier
caseBlock
private InferredJavaType
caseType
private BlockIdentifier
switchBlock
private java.util.List<Expression>
values
-
Constructor Summary
Constructors Constructor Description CaseStatement(BytecodeLoc loc, java.util.List<Expression> values, InferredJavaType caseType, BlockIdentifier switchBlock, BlockIdentifier caseBlock)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
canThrow(ExceptionCheck caught)
void
collectLValueUsage(LValueUsageCollector lValueUsageCollector)
Statement
deepClone(CloneHelper cloneHelper)
Dumper
dump(Dumper dumper)
boolean
equivalentUnder(java.lang.Object o, EquivalenceConstraint constraint)
BlockIdentifier
getCaseBlock()
BytecodeLoc
getCombinedLoc()
StructuredStatement
getStructuredStatement()
BlockIdentifier
getSwitchBlock()
java.util.List<Expression>
getValues()
boolean
isDefault()
void
replaceSingleUsageLValues(LValueRewriter lValueRewriter, SSAIdentifiers ssaIdentifiers)
void
rewriteExpressions(ExpressionRewriter expressionRewriter, SSAIdentifiers ssaIdentifiers)
-
Methods inherited from class org.benf.cfr.reader.bytecode.analysis.parse.statement.AbstractStatement
addLoc, collectLocallyMutatedVariables, collectLValueAssignments, collectObjectCreation, doesBlackListLValueReplacement, fallsToNext, getCompoundParts, getContainer, getCreatedLValue, getLoc, getRValue, getTargetStatement, isCompound, outerDeepClone, setContainer, setLifetimeHint, toString, wantsLifetimeHint
-
-
-
-
Field Detail
-
values
private java.util.List<Expression> values
-
switchBlock
private final BlockIdentifier switchBlock
-
caseBlock
private final BlockIdentifier caseBlock
-
caseType
private final InferredJavaType caseType
-
-
Constructor Detail
-
CaseStatement
public CaseStatement(BytecodeLoc loc, java.util.List<Expression> values, InferredJavaType caseType, BlockIdentifier switchBlock, BlockIdentifier caseBlock)
-
-
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)
-
getSwitchBlock
public BlockIdentifier getSwitchBlock()
-
isDefault
public boolean isDefault()
-
getStructuredStatement
public StructuredStatement getStructuredStatement()
-
getCaseBlock
public BlockIdentifier getCaseBlock()
-
getValues
public java.util.List<Expression> getValues()
-
canThrow
public boolean canThrow(ExceptionCheck caught)
- Specified by:
canThrow
in interfaceStatement
- Overrides:
canThrow
in classAbstractStatement
-
equivalentUnder
public final boolean equivalentUnder(java.lang.Object o, EquivalenceConstraint constraint)
-
-