org.aspectj.weaver.patterns
Class DeclareParents

java.lang.Object
  extended by org.aspectj.weaver.patterns.PatternNode
      extended by org.aspectj.weaver.patterns.Declare
          extended by org.aspectj.weaver.patterns.DeclareParents
All Implemented Interfaces:
IHasPosition, IHasSourceLocation
Direct Known Subclasses:
DeclareParentsMixin

public class DeclareParents
extends Declare


Field Summary
protected  TypePattern child
           
protected  boolean isExtends
           
protected  TypePatternList parents
           
 
Fields inherited from class org.aspectj.weaver.patterns.Declare
ANNOTATION, DOMINATES, ERROR_OR_WARNING, PARENTS, PARENTSMIXIN, SOFT, TYPE_ERROR_OR_WARNING
 
Fields inherited from class org.aspectj.weaver.patterns.PatternNode
end, sourceContext, start
 
Constructor Summary
  DeclareParents(TypePattern child, java.util.List parents, boolean isExtends)
           
protected DeclareParents(TypePattern child, TypePatternList parents, boolean isExtends)
           
 
Method Summary
 java.lang.Object accept(PatternNodeVisitor visitor, java.lang.Object data)
           
 boolean equals(java.lang.Object other)
           
 java.util.List<ResolvedType> findMatchingNewParents(ResolvedType onType, boolean reportErrors)
           
 TypePattern getChild()
           
 java.lang.String getNameSuffix()
          Declares have methods in the .class file against which info can be stored (for example, the annotation in the case of declare annotation).
 TypePatternList getParents()
           
 int hashCode()
           
 boolean isAdviceLike()
          Indicates if this declare should be treated like advice.
 boolean isExtends()
           
 boolean isMixin()
           
 boolean match(ResolvedType typeX)
           
 Declare parameterizeWith(java.util.Map typeVariableBindingMap, World w)
          Returns a version of this declare element in which all references to type variables are replaced with their bindings given in the map.
 boolean parentsIncludeClass(World w)
           
 boolean parentsIncludeInterface(World w)
           
static Declare read(VersionedDataInputStream s, ISourceContext context)
           
 void resolve(IScope scope)
          Returns this declare mutated
 java.lang.String toString()
           
 void write(CompressingDataOutputStream s)
           
 
Methods inherited from class org.aspectj.weaver.patterns.Declare
getDeclaringType, setDeclaringType
 
Methods inherited from class org.aspectj.weaver.patterns.PatternNode
copyLocationFrom, getEnd, getFileName, getSourceContext, getSourceLocation, getStart, readLocation, setLocation, traverse, writeLocation
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

child

protected TypePattern child

parents

protected TypePatternList parents

isExtends

protected boolean isExtends
Constructor Detail

DeclareParents

public DeclareParents(TypePattern child,
                      java.util.List parents,
                      boolean isExtends)

DeclareParents

protected DeclareParents(TypePattern child,
                         TypePatternList parents,
                         boolean isExtends)
Method Detail

match

public boolean match(ResolvedType typeX)

accept

public java.lang.Object accept(PatternNodeVisitor visitor,
                               java.lang.Object data)
Specified by:
accept in class PatternNode

parameterizeWith

public Declare parameterizeWith(java.util.Map typeVariableBindingMap,
                                World w)
Description copied from class: Declare
Returns a version of this declare element in which all references to type variables are replaced with their bindings given in the map.

Specified by:
parameterizeWith in class Declare

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

write

public void write(CompressingDataOutputStream s)
           throws java.io.IOException
Specified by:
write in class PatternNode
Throws:
java.io.IOException

read

public static Declare read(VersionedDataInputStream s,
                           ISourceContext context)
                    throws java.io.IOException
Throws:
java.io.IOException

parentsIncludeInterface

public boolean parentsIncludeInterface(World w)

parentsIncludeClass

public boolean parentsIncludeClass(World w)

resolve

public void resolve(IScope scope)
Description copied from class: Declare
Returns this declare mutated

Specified by:
resolve in class Declare

getParents

public TypePatternList getParents()

getChild

public TypePattern getChild()

isExtends

public boolean isExtends()

isAdviceLike

public boolean isAdviceLike()
Description copied from class: Declare
Indicates if this declare should be treated like advice. If true, the declare will have no effect in an abstract aspect. It will be inherited by any concrete aspects and will have an effect for each concrete aspect it is ultimately inherited by.

Specified by:
isAdviceLike in class Declare

findMatchingNewParents

public java.util.List<ResolvedType> findMatchingNewParents(ResolvedType onType,
                                                           boolean reportErrors)

getNameSuffix

public java.lang.String getNameSuffix()
Description copied from class: Declare
Declares have methods in the .class file against which info can be stored (for example, the annotation in the case of declare annotation). The name is of the form ajc$declare_XXX_NNN where XXX can optionally be set in this 'getNameSuffix()' method - depending on whether, at weave time, we want to easily differentiate between the declare methods.

Specified by:
getNameSuffix in class Declare

isMixin

public boolean isMixin()