public class Block extends AbstractStructuredStatement
Constructor and Description |
---|
Block(LinkedList<Op04StructuredStatement> containedStatements,
boolean indenting) |
Block(LinkedList<Op04StructuredStatement> containedStatements,
boolean indenting,
BlockIdentifier blockIdentifier) |
Block(Op04StructuredStatement statement) |
addLoc, canDefine, canFall, claimBlock, fallsNopToNext, findCreatedHere, getContainer, getLoc, informBlockHeirachy, isProperlyStructured, setContainer, suggestName, supportsBreak, supportsContinueBreak, toString
public Block(Op04StructuredStatement statement)
public Block(LinkedList<Op04StructuredStatement> containedStatements, boolean indenting)
public Block(LinkedList<Op04StructuredStatement> containedStatements, boolean indenting, BlockIdentifier blockIdentifier)
public BytecodeLoc getCombinedLoc()
public void flattenOthersIn()
public void addStatement(Op04StructuredStatement stm)
public static Block getBlockFor(boolean indenting, StructuredStatement... statements)
public void collectTypeUsages(TypeUsageCollector collector)
public boolean removeLastContinue(BlockIdentifier block)
public void removeLastNVReturn()
public void removeLastGoto()
public Op04StructuredStatement getLast()
public UnstructuredWhile removeLastEndWhile()
public Pair<Boolean,Op04StructuredStatement> getOneStatementIfPresent()
public List<Op04StructuredStatement> getFilteredBlockStatements()
public Optional<Op04StructuredStatement> getMaybeJustOneStatement()
public boolean inlineable()
inlineable
in interface StructuredStatement
inlineable
in class AbstractStructuredStatement
public Op04StructuredStatement getInline()
getInline
in interface StructuredStatement
getInline
in class AbstractStructuredStatement
public void combineInlineable()
public void extractLabelledBlocks()
public void combineTryCatch()
public boolean isScopeBlock()
isScopeBlock
in interface StructuredStatement
isScopeBlock
in class AbstractStructuredStatement
public void transformStructuredChildren(StructuredStatementTransformer transformer, StructuredScope scope)
public void transformStructuredChildrenInReverse(StructuredStatementTransformer transformer, StructuredScope scope)
transformStructuredChildrenInReverse
in interface StructuredStatement
transformStructuredChildrenInReverse
in class AbstractStructuredStatement
public Set<Op04StructuredStatement> getNextAfter(int x)
public boolean statementIsLast(Op04StructuredStatement needle)
public BlockIdentifier getBreakableBlockOrNull()
getBreakableBlockOrNull
in interface StructuredStatement
getBreakableBlockOrNull
in class AbstractStructuredStatement
public boolean isRecursivelyStructured()
isRecursivelyStructured
in interface StructuredStatement
isRecursivelyStructured
in class AbstractStructuredStatement
public List<Op04StructuredStatement> getBlockStatements()
public void replaceBlockStatements(Collection<Op04StructuredStatement> statements)
public void linearizeInto(List<StructuredStatement> out)
public void traceLocalVariableScope(LValueScopeDiscoverer scopeDiscoverer)
public void markCreator(LValue scopedEntity, StatementContainer<StructuredStatement> hint)
markCreator
in interface StructuredStatement
markCreator
in class AbstractStructuredStatement
public boolean alwaysDefines(LValue scopedEntity)
alwaysDefines
in interface StructuredStatement
alwaysDefines
in class AbstractStructuredStatement
public boolean isIndenting()
public void setIndenting(boolean indenting)
public boolean match(MatchIterator<StructuredStatement> matchIterator, MatchResultCollector matchResultCollector)
match
in interface Matcher<StructuredStatement>
match
in class AbstractStructuredStatement
public void rewriteExpressions(ExpressionRewriter expressionRewriter)
public boolean isEffectivelyNOP()
isEffectivelyNOP
in interface StructuredStatement
isEffectivelyNOP
in class AbstractStructuredStatement
Copyright © 2011-2021. All Rights Reserved.