org.springframework.roo.classpath.details
Class DeclaredFieldAnnotationDetails

java.lang.Object
  extended by org.springframework.roo.classpath.details.DeclaredFieldAnnotationDetails

public class DeclaredFieldAnnotationDetails
extends Object

Convenience class to hold annotation details which should be introduced to a field via an AspectJ ITD

Since:
1.1
Author:
Stefan Schmidt

Constructor Summary
DeclaredFieldAnnotationDetails(FieldMetadata field, AnnotationMetadata fieldAnnotation)
          Overloaded constructor which is used in the most typical case of ADDING an annotation to a field, not removing one.
DeclaredFieldAnnotationDetails(FieldMetadata field, AnnotationMetadata fieldAnnotation, boolean removeAnnotation)
          Constructor must contain FieldMetadata of existing field (may already contain field annotations) and a list of new Annotations which should be introduced by an AspectJ ITD.
 
Method Summary
 FieldMetadata getField()
           
 AnnotationMetadata getFieldAnnotation()
           
 boolean isRemoveAnnotation()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DeclaredFieldAnnotationDetails

public DeclaredFieldAnnotationDetails(FieldMetadata field,
                                      AnnotationMetadata fieldAnnotation)
Overloaded constructor which is used in the most typical case of ADDING an annotation to a field, not removing one.

Parameters:
field - FieldMetadata of existing field (may not be null)
fieldAnnotation - Annotation to be added to field via an ITD (may not be null)

DeclaredFieldAnnotationDetails

public DeclaredFieldAnnotationDetails(FieldMetadata field,
                                      AnnotationMetadata fieldAnnotation,
                                      boolean removeAnnotation)
Constructor must contain FieldMetadata of existing field (may already contain field annotations) and a list of new Annotations which should be introduced by an AspectJ ITD. The added annotations can not already be present in FieldMetadata.

Parameters:
field - FieldMetadata of existing field (may not be null)
fieldAnnotation - Annotation to be added to field via an ITD (may not be null)
removeAnnotation - if true, will cause the specified annotation to be REMOVED via AspectJ's "-" syntax (usually would be false)
Method Detail

getField

public FieldMetadata getField()

getFieldAnnotation

public AnnotationMetadata getFieldAnnotation()

isRemoveAnnotation

public final boolean isRemoveAnnotation()


Copyright © 2009–2015. All rights reserved.