org.codehaus.aspectwerkz.joinpoint.impl
Class ConstructorSignatureImpl

java.lang.Object
  extended by org.codehaus.aspectwerkz.joinpoint.impl.ConstructorSignatureImpl
All Implemented Interfaces:
Serializable, CodeSignature, ConstructorSignature, MemberSignature, Signature

public class ConstructorSignatureImpl
extends Object
implements ConstructorSignature

Implementation for the constructor signature.

Author:
Jonas BonŽr
See Also:
Serialized Form

Constructor Summary
ConstructorSignatureImpl(Class declaringType, Constructor constructor)
           
 
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.
 Constructor getConstructor()
          Returns the constructor.
 Class getDeclaringType()
          Returns the declaring class.
 Class[] getExceptionTypes()
          Returns the exception types declared by the code block.
 int getModifiers()
          Returns the modifiers for the signature.
 String getName()
          Returns the name (f.e. name of method of field).
 Class[] getParameterTypes()
          Returns the parameter types.
 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

ConstructorSignatureImpl

public ConstructorSignatureImpl(Class declaringType,
                                Constructor constructor)
Parameters:
declaringType -
constructor -
Method Detail

getConstructor

public Constructor getConstructor()
Returns the constructor.

Specified by:
getConstructor in interface ConstructorSignature
Returns:
the constructor

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:

getExceptionTypes

public Class[] getExceptionTypes()
Returns the exception types declared by the code block.

Specified by:
getExceptionTypes in interface CodeSignature
Returns:
the exception types

getParameterTypes

public Class[] getParameterTypes()
Returns the parameter types.

Specified by:
getParameterTypes in interface CodeSignature
Returns:
the parameter types

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.

Overrides:
toString in class Object
Returns:
a string representation


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