Class DeclareLocalClassesTransform
- java.lang.Object
-
- com.strobel.decompiler.languages.java.ast.transforms.DeclareLocalClassesTransform
-
- All Implemented Interfaces:
IAstTransform
public class DeclareLocalClassesTransform extends java.lang.Object implements IAstTransform
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
DeclareLocalClassesTransform.TypeToDeclare
-
Field Summary
Fields Modifier and Type Field Description protected AstBuilder
astBuilder
protected DecompilerContext
context
-
Constructor Summary
Constructors Constructor Description DeclareLocalClassesTransform(DecompilerContext context)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private static boolean
canMoveLocalTypeIntoSubBlock(Statement statement, TypeReference localType, boolean allowPassIntoLoops)
private boolean
declareTypeInBlock(BlockStatement block, TypeDeclaration type, boolean allowPassIntoLoops, java.util.Set<DeclareLocalClassesTransform.TypeToDeclare> typesToDeclare)
(package private) static boolean
findDeclarationPoint(TypeReference localType, boolean allowPassIntoLoops, BlockStatement block, StrongBox<Statement> declarationPoint, Statement skipUpThrough)
static boolean
findDeclarationPoint(TypeDeclaration declaration, BlockStatement block, StrongBox<Statement> declarationPoint, Statement skipUpThrough)
private static boolean
hasNestedBlocks(AstNode node)
private static boolean
referencesType(TypeReference reference, TypeReference localType)
private static boolean
referencesType(AstNode node, TypeReference localType)
private static boolean
referencesType(AstType reference, TypeReference localType)
void
run(AstNode node)
private void
run(AstNode node, DefiniteAssignmentAnalysis daa)
-
-
-
Field Detail
-
context
protected final DecompilerContext context
-
astBuilder
protected final AstBuilder astBuilder
-
-
Constructor Detail
-
DeclareLocalClassesTransform
public DeclareLocalClassesTransform(DecompilerContext context)
-
-
Method Detail
-
run
public void run(AstNode node)
- Specified by:
run
in interfaceIAstTransform
-
run
private void run(AstNode node, DefiniteAssignmentAnalysis daa)
-
declareTypeInBlock
private boolean declareTypeInBlock(BlockStatement block, TypeDeclaration type, boolean allowPassIntoLoops, java.util.Set<DeclareLocalClassesTransform.TypeToDeclare> typesToDeclare)
-
findDeclarationPoint
public static boolean findDeclarationPoint(TypeDeclaration declaration, BlockStatement block, StrongBox<Statement> declarationPoint, Statement skipUpThrough)
-
findDeclarationPoint
static boolean findDeclarationPoint(TypeReference localType, boolean allowPassIntoLoops, BlockStatement block, StrongBox<Statement> declarationPoint, Statement skipUpThrough)
-
canMoveLocalTypeIntoSubBlock
private static boolean canMoveLocalTypeIntoSubBlock(Statement statement, TypeReference localType, boolean allowPassIntoLoops)
-
referencesType
private static boolean referencesType(AstType reference, TypeReference localType)
-
referencesType
private static boolean referencesType(TypeReference reference, TypeReference localType)
-
referencesType
private static boolean referencesType(AstNode node, TypeReference localType)
-
hasNestedBlocks
private static boolean hasNestedBlocks(AstNode node)
-
-