org.codehaus.aspectwerkz.joinpoint.impl
Class FieldSignatureImpl

java.lang.Object
  extended byorg.codehaus.aspectwerkz.joinpoint.impl.FieldSignatureImpl
All Implemented Interfaces:
FieldSignature, MemberSignature, Serializable, Signature

public class FieldSignatureImpl
extends Object
implements FieldSignature

Implementation for the field signature.

Author:
Jonas Bonér
See Also:
Serialized Form

Constructor Summary
FieldSignatureImpl(Class declaringType, Field field)
           
 
Method Summary
 Annotation getAnnotation(String annotationName)
          Return the annotation with a specific name.
 List getAnnotationInfos()
          Return all the annotations

Each annotation is wrapped in AnnotationInfoinstance.

 List getAnnotations(String annotationName)
          Return a list with the annotations with a specific name.
 Class getDeclaringType()
          Returns the declaring class.
 Field getField()
          Returns the field.
 Class getFieldType()
          Returns the field type.
 int getModifiers()
          Returns the modifiers for the signature.
 String getName()
          Returns the name (f.e. name of method of field).
 String toString()
          Returns a string representation of the signature.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FieldSignatureImpl

public FieldSignatureImpl(Class declaringType,
                          Field field)
Parameters:
field -
declaringType -
Method Detail

getDeclaringType

public Class getDeclaringType()
Returns the declaring class.

Specified by:
getDeclaringType in interface Signature
Returns:
the declaring class

getModifiers

public int getModifiers()
Returns the modifiers for the signature.

Could be used like this:

 boolean isPublic = java.lang.reflect.Modifier.isPublic(signature.getModifiers());
 

Specified by:
getModifiers in interface Signature
Returns:
the mofifiers

getName

public String getName()
Returns the name (f.e. name of method of field).

Specified by:
getName in interface Signature
Returns:
the name

getField

public Field getField()
Returns the field.

Specified by:
getField in interface FieldSignature
Returns:
the field

getFieldType

public Class getFieldType()
Returns the field type.

Specified by:
getFieldType in interface FieldSignature
Returns:
the field type

getAnnotation

public Annotation getAnnotation(String annotationName)
Return the annotation with a specific name.

Specified by:
getAnnotation in interface MemberSignature
Parameters:
annotationName - the annotation name
Returns:
the annotation or null

getAnnotations

public List getAnnotations(String annotationName)
Return a list with the annotations with a specific name.

Specified by:
getAnnotations in interface MemberSignature
Parameters:
annotationName - the annotation name
Returns:
the annotations in a list (can be empty)

getAnnotationInfos

public List getAnnotationInfos()
Return all the annotations

Each annotation is wrapped in AnnotationInfoinstance.

Specified by:
getAnnotationInfos in interface MemberSignature
Returns:
a list with the annotations

toString

public String toString()
Returns a string representation of the signature.

Returns:
a string representation


Copyright © 2002-2004 Jonas Bonér, Alexandre Vasseur. All Rights Reserved.