Package net.jangaroo.jooc
Class AbstractScope
- java.lang.Object
-
- net.jangaroo.jooc.AbstractScope
-
- All Implemented Interfaces:
Scope
- Direct Known Subclasses:
DeclarationScope,LabelScope
public abstract class AbstractScope extends Object implements Scope
-
-
Constructor Summary
Constructors Constructor Description AbstractScope(Scope parent)
-
Method Summary
-
-
-
Constructor Detail
-
AbstractScope
public AbstractScope(Scope parent)
-
-
Method Detail
-
getParentScope
public Scope getParentScope()
- Specified by:
getParentScopein interfaceScope
-
addImport
public void addImport(ImportDirective importDirective)
-
getDefiningNode
public AstNode getDefiningNode()
- Specified by:
getDefiningNodein interfaceScope
-
declareIde
public IdeDeclaration declareIde(IdeDeclaration decl)
- Specified by:
declareIdein interfaceScope
-
lookupLabel
public LabeledStatement lookupLabel(Ide ide)
- Specified by:
lookupLabelin interfaceScope
-
lookupDeclaration
public IdeDeclaration lookupDeclaration(Ide ide)
- Specified by:
lookupDeclarationin interfaceScope
-
lookupDeclaration
public IdeDeclaration lookupDeclaration(Ide ide, boolean failOnAmbigousImport)
- Specified by:
lookupDeclarationin interfaceScope
-
isDeclared
public boolean isDeclared(Ide ide)
- Specified by:
isDeclaredin interfaceScope
-
findFreeAuxVar
public Ide findFreeAuxVar(String preferredName)
- Specified by:
findFreeAuxVarin interfaceScope
-
createAuxVar
public Ide createAuxVar(String preferredName)
Description copied from interface:ScopePreferred name must be a valid AS identifier!- Specified by:
createAuxVarin interfaceScope- See Also:
Ide.IDE_PATTERN
-
getCurrentLoop
public LoopStatement getCurrentLoop()
- Specified by:
getCurrentLoopin interfaceScope
-
getCurrentLoopOrSwitch
public Statement getCurrentLoopOrSwitch()
- Specified by:
getCurrentLoopOrSwitchin interfaceScope
-
getCompilationUnit
public CompilationUnit getCompilationUnit()
- Specified by:
getCompilationUnitin interfaceScope
-
getPackageDeclaration
public PackageDeclaration getPackageDeclaration()
- Specified by:
getPackageDeclarationin interfaceScope
-
getClassDeclaration
public ClassDeclaration getClassDeclaration()
- Specified by:
getClassDeclarationin interfaceScope
-
getPackageDeclarationScope
public DeclarationScope getPackageDeclarationScope()
- Specified by:
getPackageDeclarationScopein interfaceScope
-
getCompiler
public JangarooParser getCompiler()
- Specified by:
getCompilerin interfaceScope
-
getClassDeclaration
public ClassDeclaration getClassDeclaration(String qname)
- Specified by:
getClassDeclarationin interfaceScope
-
getExpressionType
public ExpressionType getExpressionType(net.jangaroo.utils.AS3Type as3Type)
- Specified by:
getExpressionTypein interfaceScope
-
getFunctionSignature
public FunctionSignature getFunctionSignature(MethodType methodType, Parameters params, ExpressionType returnType)
- Specified by:
getFunctionSignaturein interfaceScope
-
getExpressionType
public ExpressionType getExpressionType(TypeRelation typeRelation)
- Specified by:
getExpressionTypein interfaceScope
-
getExpressionType
public ExpressionType getExpressionType(IdeDeclaration declaration)
- Specified by:
getExpressionTypein interfaceScope
-
findArrayElementTypeInSuperTypes
public static TypeDeclaration findArrayElementTypeInSuperTypes(IdeDeclaration declaration)
-
getMethodDeclaration
public FunctionDeclaration getMethodDeclaration()
- Specified by:
getMethodDeclarationin interfaceScope
-
getFunctionExpr
public FunctionExpr getFunctionExpr()
- Specified by:
getFunctionExprin interfaceScope
-
-