org.aspectj.compiler.base.ast
Class ArrayExpr

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.AssignableExpr
                      extended byorg.aspectj.compiler.base.ast.ArrayExpr

public class ArrayExpr
extends AssignableExpr


Field Summary
protected  Expr expr
           
protected  Expr index
           
 
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
  ArrayExpr(Expr _expr, Expr _index)
           
protected ArrayExpr(SourceLocation source)
           
  ArrayExpr(SourceLocation location, Expr _expr, Expr _index)
           
 
Method Summary
protected  void cgAssignment(org.aspectj.compiler.base.bcg.CodeBuilder cb)
          Generate code to actually assign into this assignable.
protected  void cgDupLvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
          Generates code to duplicate the top lvalue on the stack.
protected  void cgDupRvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
          Generates code to duplicate the top rvalue on the stack and places it BELOW the lvalue that may be just below it.
protected  void cgLtoRvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
          Generate code to remove the lvalue at the top of the stack (if any) and place the appropriate rvalue on the stack.
protected  void cgLvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
          Generate code to place the lvalue of this expression on the top of the stack.
 ASTObject copyWalk(CopyWalker walker)
           
protected  Type discoverType()
           
 ASTObject getChildAt(int childIndex)
           
 int getChildCount()
           
 java.lang.String getChildNameAt(int childIndex)
           
 java.lang.String getDefaultDisplayName()
           
 Expr getExpr()
           
 Expr getIndex()
           
 void setChildAt(int childIndex, ASTObject child)
           
 void setExpr(Expr _expr)
           
 void setIndex(Expr _index)
           
 void unparse(org.aspectj.compiler.base.CodeWriter writer)
           
 
Methods inherited from class org.aspectj.compiler.base.ast.AssignableExpr
cgValue, isIncable, isLhs
 
Methods inherited from class org.aspectj.compiler.base.ast.Expr
assertType, canBeCopied, cgBuffer, cgEffect, cgTest, cgValue, checkSpec, cleanup, getType, isAssignableTo, isConstantFalse, isConstantTrue, isConstantZero, isInConstructorCallExpr, isInExprStmt, isLegalStmt, isMethodConvertableTo, isUltimatelyLiteral, makeQualifiedThis, makeReference, postCopy, setType, showOperatorTypeError, showOperatorTypeError, walkCleanup, walkFrameLoc
 
Methods inherited from class org.aspectj.compiler.base.ast.ASTObject
addComment, buildAccessMethod, checkNoSharing, clearComment, clearParent, contains, containsTypes, copy, display, fixAccessPost, 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, hasLegalProtectedAccess, hasSource, hasSourceLocation, implementMixin, indexOf, inStaticContext, isLanguageVisible, isLeaf, isSynthetic, makeChild, makeChild, postAssignmentCheck, postCleanup, postFixAST, postImplementMixin, postInnerAccess, postInnerInfo, postLift, postMove, postScope, 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, walkFlow, 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

index

protected Expr index
Constructor Detail

ArrayExpr

public ArrayExpr(SourceLocation location,
                 Expr _expr,
                 Expr _index)

ArrayExpr

protected ArrayExpr(SourceLocation source)

ArrayExpr

public ArrayExpr(Expr _expr,
                 Expr _index)
Method Detail

discoverType

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

unparse

public void unparse(org.aspectj.compiler.base.CodeWriter writer)
             throws java.io.IOException
Overrides:
unparse in class ASTObject
Throws:
java.io.IOException

cgLvalue

protected void cgLvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
Description copied from class: AssignableExpr
Generate code to place the lvalue of this expression on the top of the stack. Only assignable expressions have lvalues. Some assignable expressions (such as static field access expressions) do not have lvalues, and for them this method is a noop.

Specified by:
cgLvalue in class AssignableExpr

cgLtoRvalue

protected void cgLtoRvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
Description copied from class: AssignableExpr
Generate code to remove the lvalue at the top of the stack (if any) and place the appropriate rvalue on the stack. Assumes that said lvalue was generated by this expression.

Specified by:
cgLtoRvalue in class AssignableExpr

cgAssignment

protected void cgAssignment(org.aspectj.compiler.base.bcg.CodeBuilder cb)
Description copied from class: AssignableExpr
Generate code to actually assign into this assignable. Assumes that the new rvalue is at the top of the stack, and that this expression's lvalue (if any) is just below it.

Specified by:
cgAssignment in class AssignableExpr

cgDupLvalue

protected void cgDupLvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
Description copied from class: AssignableExpr
Generates code to duplicate the top lvalue on the stack. Assumes that said lvalue on the stack was generated by this expression.

Specified by:
cgDupLvalue in class AssignableExpr

cgDupRvalue

protected void cgDupRvalue(org.aspectj.compiler.base.bcg.CodeBuilder cb)
Description copied from class: AssignableExpr
Generates code to duplicate the top rvalue on the stack and places it BELOW the lvalue that may be just below it. Assumes that said lvalue and rvalue on the stack were generated by this expression.

Specified by:
cgDupRvalue in class AssignableExpr

getExpr

public Expr getExpr()

setExpr

public void setExpr(Expr _expr)

getIndex

public Expr getIndex()

setIndex

public void setIndex(Expr _index)

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 AssignableExpr