org.aspectj.compiler.base.ast
Class MethodDec
java.lang.Object
org.aspectj.compiler.base.CompilerObject
org.aspectj.compiler.base.ast.ASTObject
org.aspectj.compiler.base.ast.Stmt
org.aspectj.compiler.base.ast.Dec
org.aspectj.compiler.base.ast.CodeDec
org.aspectj.compiler.base.ast.MethodDec
- All Implemented Interfaces:
- AspectMember, ClassMember, PossibleSoftThrowable
- public class MethodDec
- extends CodeDec
- implements AspectMember, ClassMember
Constructor Summary |
|
MethodDec(Modifiers modifiers,
MethodDec methdec)
|
|
MethodDec(Modifiers modifiers,
TypeD resultTypeD,
java.lang.String id,
Formals formals,
BlockStmt block)
|
|
MethodDec(Modifiers modifiers,
TypeD resultTypeD,
java.lang.String id,
Formals formals,
TypeDs _throws,
BlockStmt block)
|
protected |
MethodDec(SourceLocation source)
|
|
MethodDec(SourceLocation source,
Modifiers modifiers,
TypeD resultTypeD,
java.lang.String id,
Formals formals,
TypeDs _throws,
BlockStmt block)
|
|
MethodDec(SourceLocation location,
Modifiers _modifiers,
TypeD _resultTypeD,
java.lang.String _id,
Formals _formals,
TypeDs __throws,
CodeBody _body)
|
|
MethodDec(SourceLocation source,
Modifiers modifiers,
Type resultType,
java.lang.String id,
Formals formals,
TypeDs _throws,
BlockStmt block)
|
Methods inherited from class org.aspectj.compiler.base.ast.CodeDec |
addThrows, addThrowsType, appearsStaticToCaller, blockToBody, canThrow, cgMember, cleanup, computeMinimalThrows, conflictsWith, getBody, getCallExprs, getEffectivelyFinalFormals, getFormals, getFrameSize, getModifiers, getPossibleCheckedExceptions, getResultType, getThrows, hasThis, isAlmostApplicable, isApplicable, isMoreSpecificThan, isSoftThrowable, postCleanup, postScope, setBody, setBody, setFormals, setFrameSize, setModifiers, setSoftThrowable, setThrows, setupFlowWalker, walkAnalysis, walkCleanup, walkFlow, walkFrameLoc, walkInnerInfo |
Methods inherited from class org.aspectj.compiler.base.ast.Dec |
addIntroducedFromType, dominates, forcePublic, getBytecodeId, getCorrespondingSemanticObject, getDeclaringType, getLexicalType, getName, getOutermostLexicalType, getSignatureString, inStaticContext, isAbstract, isAccessible, isAccessible, isDeprecated, isFinal, isInherited, isIntroduced, isLanguageVisible, isMoreAccessibleThan, isPrivate, isProtected, isPublic, isStatic, isSynthetic, lookupDeclaringType, lookupLexicalType, makeBlockScope, postCopy, preCopy, preMove, requireStmt, samePackage, setAllEnclosingTypes, setBytecodeId, setDeclaringType, setDeprecated, setExplicitlyNonSynthetic, setFromLexicalScope, setLanguageVisible, setLexicalType, walkForwardReference, writeModifiers, writeNames |
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, getEnclosingCodeDec, getEnclosingDec, getEndColumn, getEndLine, getEndPosition, getFormalComment, getOutermostBytecodeType, getParent, getSourceDirectoryName, getSourceFile, getSourceFileName, getSourceLocation, getStartPosition, hasLegalProtectedAccess, hasSource, hasSourceLocation, implementMixin, indexOf, isLeaf, makeChild, makeChild, postAssignmentCheck, postInnerAccess, postInnerInfo, postLift, postMove, preAssignmentCheck, preIntroduction, preLift, remove, remove, removeChildAt, replaceWith, setFormalComment, setParent, setParents, setSource, setSourceLocation, setSyntheticSource, showError, showMessage, showTypeError, showWarning, toString, unparse, walk, walkAssignmentCheck, 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 |
resultTypeD
protected TypeD resultTypeD
id
protected java.lang.String id
MethodDec
public MethodDec(SourceLocation source,
Modifiers modifiers,
TypeD resultTypeD,
java.lang.String id,
Formals formals,
TypeDs _throws,
BlockStmt block)
MethodDec
public MethodDec(Modifiers modifiers,
TypeD resultTypeD,
java.lang.String id,
Formals formals,
TypeDs _throws,
BlockStmt block)
MethodDec
public MethodDec(Modifiers modifiers,
TypeD resultTypeD,
java.lang.String id,
Formals formals,
BlockStmt block)
MethodDec
public MethodDec(SourceLocation source,
Modifiers modifiers,
Type resultType,
java.lang.String id,
Formals formals,
TypeDs _throws,
BlockStmt block)
MethodDec
public MethodDec(Modifiers modifiers,
MethodDec methdec)
MethodDec
public MethodDec(SourceLocation location,
Modifiers _modifiers,
TypeD _resultTypeD,
java.lang.String _id,
Formals _formals,
TypeDs __throws,
CodeBody _body)
MethodDec
protected MethodDec(SourceLocation source)
cgTop
public void cgTop(org.aspectj.compiler.base.bcg.CodeBuilder cb)
- Description copied from class:
Stmt
- The purpose of this procedure is to dispatch to
#cg
, but to perform an invariant check beforehand to make
sure the current stack size is zero. This method is final only
because it seems unlikely that anybody would want to override
it (they should rather provide a definition for #cg
). If there is a good reason to override this, the
final modifier can be removed.
- Specified by:
cgTop
in interface AspectMember
- Overrides:
cgTop
in class Stmt
postFixAST
public ASTObject postFixAST(org.aspectj.compiler.base.ASTFixerPass fixer)
- Overrides:
postFixAST
in class ASTObject
postImplementMixin
public ASTObject postImplementMixin(org.aspectj.compiler.crosscuts.MixinImplementationPass fixer)
- Overrides:
postImplementMixin
in class ASTObject
preScope
public void preScope(ScopeWalker walker)
- Overrides:
preScope
in class CodeDec
getExpr
public Expr getExpr()
toShortString
public java.lang.String toShortString()
- Specified by:
toShortString
in class Dec
getKind
public java.lang.String getKind()
- Specified by:
getKind
in class Dec
makeCorrespondingSemanticObject
public SemanticObject makeCorrespondingSemanticObject()
- Overrides:
makeCorrespondingSemanticObject
in class Dec
getMethod
public Method getMethod()
checkSpec
public void checkSpec()
- Overrides:
checkSpec
in class CodeDec
isEffectivelyAbstract
public boolean isEffectivelyAbstract(Type inType)
checkOverride
public boolean checkOverride(Type inType,
Dec otherDec)
- Overrides:
checkOverride
in class Dec
overrides
public boolean overrides(MethodDec other)
getMatchingMethods
public java.util.Set getMatchingMethods()
getMatchingSignatureTypes
public java.util.Set getMatchingSignatureTypes()
getBackdoorMethod
public MethodDec getBackdoorMethod()
unparse
public void unparse(org.aspectj.compiler.base.CodeWriter writer)
- Specified by:
unparse
in interface AspectMember
- Overrides:
unparse
in class ASTObject
cgCodeMember
protected void cgCodeMember(org.aspectj.compiler.base.bcg.CodeBuilder cb)
- Description copied from class:
CodeDec
- generate code for the body. Assumes there is a body.
- Overrides:
cgCodeMember
in class CodeDec
- Parameters:
cb
- the codeBuilder into which to generate code
getDescriptor
public java.lang.String getDescriptor()
- Description copied from class:
CodeDec
- return the bytecode type descriptor for the member.
- Overrides:
getDescriptor
in class CodeDec
getStackDelta
public int getStackDelta()
- Description copied from class:
CodeDec
- return the change in stack that would result from invoking
this codeDec. This is the size of the return value minus the
size of the argument values (including the implicit this
object). It is typically negative for coded members with
arguments.
- Overrides:
getStackDelta
in class CodeDec
preThreading
public void preThreading(org.aspectj.compiler.base.LocalClassPass.ThreadingWalker walker)
- Overrides:
preThreading
in class ASTObject
postThreading
public ASTObject postThreading(org.aspectj.compiler.base.LocalClassPass.ThreadingWalker walker)
- Overrides:
postThreading
in class ASTObject
getResultTypeD
public TypeD getResultTypeD()
- Specified by:
getResultTypeD
in class CodeDec
setResultTypeD
public void setResultTypeD(TypeD _resultTypeD)
getId
public java.lang.String getId()
- Specified by:
getId
in class CodeDec
setId
public void setId(java.lang.String _id)
- Overrides:
setId
in class Dec
copyWalk
public ASTObject copyWalk(CopyWalker walker)
- Overrides:
copyWalk
in class ASTObject
getChildAt
public ASTObject getChildAt(int childIndex)
- Overrides:
getChildAt
in class CodeDec
getChildNameAt
public java.lang.String getChildNameAt(int childIndex)
- Overrides:
getChildNameAt
in class CodeDec
setChildAt
public void setChildAt(int childIndex,
ASTObject child)
- Overrides:
setChildAt
in class CodeDec
getChildCount
public int getChildCount()
- Overrides:
getChildCount
in class CodeDec
getDefaultDisplayName
public java.lang.String getDefaultDisplayName()
- Overrides:
getDefaultDisplayName
in class CodeDec