A common base class of AST helper methods which can be shared across the classic and new parsers
Modifiers | Name | Description |
---|---|---|
protected ModuleNode |
output |
|
protected static Map |
resolutions |
Constructor and description |
---|
ASTHelper
(SourceUnit controller, ClassLoader classLoader) |
ASTHelper
() |
Type Params | Return Type | Name and description |
---|---|---|
|
protected void |
addImport(ClassNode type, String name, String aliasName) |
|
protected void |
addImport(ClassNode type, String name, String aliasName, List<AnnotationNode> annotations) |
|
protected void |
addStarImport(String importPackage) |
|
protected void |
addStarImport(String importPackage, List<AnnotationNode> annotations) |
|
protected void |
addStaticImport(ClassNode type, String name, String alias) |
|
protected void |
addStaticImport(ClassNode type, String name, String alias, List<AnnotationNode> annotations) |
|
protected void |
addStaticStarImport(ClassNode type, String importClass) |
|
protected void |
addStaticStarImport(ClassNode type, String importClass, List<AnnotationNode> annotations) |
|
static String |
dot(String base, String name)
|
|
protected String |
dot(String base) A synonym for dot( base, "" ) . |
|
ClassLoader |
getClassLoader() Returns our class loader (as supplied on construction). |
|
SourceUnit |
getController() |
|
String |
getPackageName() |
|
protected void |
makeModule() |
|
void |
setClassLoader(ClassLoader classLoader) |
|
void |
setController(SourceUnit controller) |
|
PackageNode |
setPackage(String packageName, List<AnnotationNode> annotations) |
|
void |
setPackageName(String packageName) |
base
- typically a packagename
- typically a simple unqualified class nameReturns our class loader (as supplied on construction).
Copyright © 2003-2017 The Apache Software Foundation. All rights reserved.