org.aspectj.compiler.base.ast
Class CallExpr

java.lang.Object
  extended byorg.aspectj.compiler.base.CompilerObject
      extended byorg.aspectj.compiler.base.ast.ASTObject
          extended byorg.aspectj.compiler.base.ast.Expr
              extended byorg.aspectj.compiler.base.ast.JavaExpr
                  extended byorg.aspectj.compiler.base.ast.AnyCallExpr
                      extended byorg.aspectj.compiler.base.ast.CallExpr
All Implemented Interfaces:
PossibleSoftThrowable, SOLink

public class CallExpr
extends AnyCallExpr
implements SOLink


Field Summary
protected  Exprs args
           
protected  Expr expr
           
protected  java.lang.String id
           
protected  boolean isSuper
           
protected  Method method
           
 
Fields inherited from class org.aspectj.compiler.base.ast.Expr
type
 
Fields inherited from class org.aspectj.compiler.base.ast.ASTObject
dummySource, parent, sourceLocation
 
Constructor Summary
  CallExpr(Expr _fexpr, Exprs _args)
           
  CallExpr(Expr expr, java.lang.String id)
           
  CallExpr(Expr expr, java.lang.String _id, Exprs _args)
           
protected CallExpr(Method toMethod, Expr instance, Exprs args)
           
protected CallExpr(SourceLocation source)
           
protected CallExpr(SourceLocation source, Expr expr, java.lang.String id)
           
  CallExpr(SourceLocation source, Expr expr, java.lang.String _id, Exprs _args)
           
  CallExpr(SourceLocation location, Expr _expr, java.lang.String _id, Exprs _args, Method _method, boolean _isSuper)
           
protected CallExpr(SourceLocation source, Method toMethod, Expr instance, Exprs args)
           
protected CallExpr(SourceLocation source, java.lang.String _id, Exprs _args)
           
  CallExpr(java.lang.String _id, Exprs _args)
           
 
Method Summary
 MethodDec buildAccessMethod(org.aspectj.compiler.base.InnerAccessFixer w)
          Builds a method that would perform the actions of this expression.
protected  void cgValue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
          Leaves the value of this expression on the stack.
 void checkSpec()
           
 ASTObject copyWalk(CopyWalker walker)
           
 Type discoverType()
           
 ASTObject fixAccessPost(org.aspectj.compiler.crosscuts.AccessFixer fixer)
           
 Exprs getArgs()
           
 Type getCalledType()
           
 ASTObject getChildAt(int childIndex)
           
 int getChildCount()
           
 java.lang.String getChildNameAt(int childIndex)
           
 CodeDec getCodeDec()
           
 java.lang.String getDefaultDisplayName()
           
 Expr getExpr()
           
 Expr getExprOrThis()
           
 java.lang.String getId()
           
 boolean getIsSuper()
           
 Method getMethod()
           
 MethodDec getMethodDec()
           
 Type getReturnType()
           
 SemanticObject getTarget()
           
 boolean hasLegalProtectedAccess(Type fromType)
          Section 6.6.2.1 from JLSv2 E.Id requires that E is subtype of S
 boolean isLegalStmt()
           
 ASTObject postFixAST(org.aspectj.compiler.base.ASTFixerPass fixer)
           
 ASTObject postInnerAccess(org.aspectj.compiler.base.InnerAccessFixer w)
          Converts an expression accessing inaccessable context to one that is legal.
 void postInnerInfo(org.aspectj.compiler.base.InnerInfoPass w)
           
 ASTObject postMove(MovingWalker walker)
           
 ASTObject postScope(ScopeWalker walker)
           
 void setArgs(Exprs _args)
           
 void setChildAt(int childIndex, ASTObject child)
           
 void setExpr(Expr _expr)
           
 void setId(java.lang.String _id)
           
 void setIsSuper(boolean _isSuper)
           
 void setMethod(Method _method)
           
 void setMethodDec(MethodDec md)
           
 void setTarget(SemanticObject newTarget)
           
 Expr toExpr()
           
 boolean tryToInline(Type bytecodeType)
           
 void unparse(org.aspectj.compiler.base.CodeWriter writer)
           
 void walkFlow(org.aspectj.compiler.base.FlowCheckerPass w)
           
 
Methods inherited from class org.aspectj.compiler.base.ast.AnyCallExpr
isSoftThrowable, setSoftThrowable
 
Methods inherited from class org.aspectj.compiler.base.ast.Expr
assertType, canBeCopied, cgBuffer, cgEffect, cgTest, cgValue, cleanup, getType, isAssignableTo, isConstantFalse, isConstantTrue, isConstantZero, isInConstructorCallExpr, isInExprStmt, isMethodConvertableTo, isUltimatelyLiteral, makeQualifiedThis, makeReference, postCopy, setType, showOperatorTypeError, showOperatorTypeError, walkCleanup, walkFrameLoc
 
Methods inherited from class org.aspectj.compiler.base.ast.ASTObject
addComment, checkNoSharing, clearComment, clearParent, contains, containsTypes, copy, display, fixAST, fromSource, getAST, getBeginColumn, getBeginLine, getBytecodeType, getBytecodeTypeDec, getComment, getCompilationUnit, getDeclaringType, getEnclosingCodeDec, getEnclosingDec, getEndColumn, getEndLine, getEndPosition, getFormalComment, getLexicalType, getOutermostBytecodeType, getOutermostLexicalType, getParent, getSourceDirectoryName, getSourceFile, getSourceFileName, getSourceLocation, getStartPosition, hasSource, hasSourceLocation, implementMixin, indexOf, inStaticContext, isLanguageVisible, isLeaf, isSynthetic, makeChild, makeChild, postAssignmentCheck, postCleanup, postImplementMixin, postLift, postThreading, preAssignmentCheck, preCopy, preIntroduction, preLift, preMove, preScope, preThreading, remove, remove, removeChildAt, replaceWith, setFormalComment, setParent, setParents, setSource, setSourceLocation, setSyntheticSource, showError, showMessage, showTypeError, showWarning, toShortString, toString, unparse, walk, walkAnalysis, walkAssignmentCheck, walkForwardReference, walkInnerInfo, walkMemberMunger, walkScope
 
Methods inherited from class org.aspectj.compiler.base.CompilerObject
getCompiler, getOptions, getTypeManager, getWorld
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

expr

protected Expr expr

id

protected java.lang.String id

args

protected Exprs args

method

protected Method method

isSuper

protected boolean isSuper
Constructor Detail

CallExpr

protected CallExpr(SourceLocation source,
                   Expr expr,
                   java.lang.String id)

CallExpr

public CallExpr(Expr expr,
                java.lang.String id)

CallExpr

protected CallExpr(SourceLocation source,
                   Method toMethod,
                   Expr instance,
                   Exprs args)

CallExpr

protected CallExpr(SourceLocation source,
                   java.lang.String _id,
                   Exprs _args)

CallExpr

public CallExpr(SourceLocation source,
                Expr expr,
                java.lang.String _id,
                Exprs _args)

CallExpr

protected CallExpr(Method toMethod,
                   Expr instance,
                   Exprs args)

CallExpr

public CallExpr(java.lang.String _id,
                Exprs _args)

CallExpr

public CallExpr(Expr _fexpr,
                Exprs _args)

CallExpr

public CallExpr(Expr expr,
                java.lang.String _id,
                Exprs _args)

CallExpr

public CallExpr(SourceLocation location,
                Expr _expr,
                java.lang.String _id,
                Exprs _args,
                Method _method,
                boolean _isSuper)

CallExpr

protected CallExpr(SourceLocation source)
Method Detail

toExpr

public Expr toExpr()

walkFlow

public void walkFlow(org.aspectj.compiler.base.FlowCheckerPass w)
Overrides:
walkFlow in class ASTObject

postMove

public ASTObject postMove(MovingWalker walker)
Overrides:
postMove in class ASTObject

postScope

public ASTObject postScope(ScopeWalker walker)
Overrides:
postScope in class ASTObject

postInnerInfo

public void postInnerInfo(org.aspectj.compiler.base.InnerInfoPass w)
Overrides:
postInnerInfo in class ASTObject

hasLegalProtectedAccess

public boolean hasLegalProtectedAccess(Type fromType)
Section 6.6.2.1 from JLSv2 E.Id requires that E is subtype of S

Overrides:
hasLegalProtectedAccess in class ASTObject

checkSpec

public void checkSpec()
Overrides:
checkSpec in class Expr

isLegalStmt

public boolean isLegalStmt()
Overrides:
isLegalStmt in class Expr

postFixAST

public ASTObject postFixAST(org.aspectj.compiler.base.ASTFixerPass fixer)
Overrides:
postFixAST in class ASTObject

fixAccessPost

public ASTObject fixAccessPost(org.aspectj.compiler.crosscuts.AccessFixer fixer)
Overrides:
fixAccessPost in class ASTObject

getMethodDec

public MethodDec getMethodDec()

setMethodDec

public void setMethodDec(MethodDec md)

getCodeDec

public CodeDec getCodeDec()
Specified by:
getCodeDec in class AnyCallExpr

getTarget

public SemanticObject getTarget()
Specified by:
getTarget in interface SOLink

setTarget

public void setTarget(SemanticObject newTarget)
Specified by:
setTarget in interface SOLink

getReturnType

public Type getReturnType()
Specified by:
getReturnType in class AnyCallExpr

getCalledType

public Type getCalledType()
Specified by:
getCalledType in class AnyCallExpr

discoverType

public Type discoverType()
Specified by:
discoverType in class Expr

getExprOrThis

public Expr getExprOrThis()
Specified by:
getExprOrThis in class AnyCallExpr

tryToInline

public boolean tryToInline(Type bytecodeType)

unparse

public void unparse(org.aspectj.compiler.base.CodeWriter writer)
Overrides:
unparse in class ASTObject

postInnerAccess

public ASTObject postInnerAccess(org.aspectj.compiler.base.InnerAccessFixer w)
Description copied from class: ASTObject
Converts an expression accessing inaccessable context to one that is legal.

Overrides:
postInnerAccess in class ASTObject

buildAccessMethod

public MethodDec buildAccessMethod(org.aspectj.compiler.base.InnerAccessFixer w)
Description copied from class: ASTObject
Builds a method that would perform the actions of this expression. The InnerAccessFixer object keeps a cache of such methods to provide to the InnerAccessFixer walk, but if no appropriate method has yet been built, the original expression is the one that knows how to build it. This should only be overridden in PrefixExpr, PostfixExpr, FieldAccessExpr, AssignExpr, and CallExpr. If and when we do cookie methods for constructor, we may also need to override this in NewInstanceExpr and ConstructorCallExpr.

Overrides:
buildAccessMethod in class ASTObject

cgValue

protected void cgValue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
Description copied from class: Expr
Leaves the value of this expression on the stack. May self-call Expr.cgTest(CodeBuilder, Label, Label).

Overrides:
cgValue in class Expr

getExpr

public Expr getExpr()
Specified by:
getExpr in class AnyCallExpr

setExpr

public void setExpr(Expr _expr)
Specified by:
setExpr in class AnyCallExpr

getId

public java.lang.String getId()
Specified by:
getId in class AnyCallExpr

setId

public void setId(java.lang.String _id)

getArgs

public Exprs getArgs()
Specified by:
getArgs in class AnyCallExpr

setArgs

public void setArgs(Exprs _args)
Specified by:
setArgs in class AnyCallExpr

getMethod

public Method getMethod()

setMethod

public void setMethod(Method _method)

getIsSuper

public boolean getIsSuper()

setIsSuper

public void setIsSuper(boolean _isSuper)

copyWalk

public ASTObject copyWalk(CopyWalker walker)
Overrides:
copyWalk in class ASTObject

getChildAt

public ASTObject getChildAt(int childIndex)
Overrides:
getChildAt in class ASTObject

getChildNameAt

public java.lang.String getChildNameAt(int childIndex)
Overrides:
getChildNameAt in class ASTObject

setChildAt

public void setChildAt(int childIndex,
                       ASTObject child)
Overrides:
setChildAt in class ASTObject

getChildCount

public int getChildCount()
Overrides:
getChildCount in class ASTObject

getDefaultDisplayName

public java.lang.String getDefaultDisplayName()
Overrides:
getDefaultDisplayName in class AnyCallExpr