org.eclipse.jpt.core.resource.java
Interface JavaResourcePersistentAttribute

All Superinterfaces:
JavaResourceNode, JavaResourcePersistentMember, Model

public interface JavaResourcePersistentAttribute
extends JavaResourcePersistentMember

Java source code or binary persistent attribute (field or property) Provisional API: This interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.core.resource.java.JavaResourceNode
JavaResourceNode.Root
 
Field Summary
static java.lang.String MODIFIERS_PROPERTY
           
static java.lang.String TYPE_INTERFACE_NAMES_COLLECTION
           
static java.lang.String TYPE_IS_ENUM_PROPERTY
           
static java.lang.String TYPE_IS_INTERFACE_PROPERTY
           
static java.lang.String TYPE_NAME_PROPERTY
           
static java.lang.String TYPE_SUPERCLASS_NAMES_COLLECTION
           
static java.lang.String TYPE_TYPE_ARGUMENT_NAMES_COLLECTION
           
 
Fields inherited from interface org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember
MAPPING_ANNOTATIONS_COLLECTION, PERSISTABLE_PROPERTY, SUPPORTING_ANNOTATIONS_COLLECTION
 
Method Summary
 int getModifiers()
           
 java.lang.String getName()
          The Java resource persistent attribute's name does not change.
 Annotation getNullMappingAnnotation(java.lang.String annotationName)
          Return a null mapping annotation with the specified name.
 AccessType getSpecifiedAccess()
          Return the access type explicitly specified by the javax.persistence.Access annotation.
 java.lang.String getTypeName()
          Return the resolved, qualified name of the attribute's type (e.g.
 java.lang.String getTypeTypeArgumentName(int index)
           
 boolean hasAnyPersistenceAnnotations()
          Return whether the attribute has any mapping or non-mapping annotations (of course only persistence-related annotations).
 boolean isField()
          Whether the Java resource persistent attribute is a field does not change.
 boolean isFor(MethodSignature methodSignature, int occurrence)
          Return whether the Java resource persistent attribute is for the specified method.
 boolean isProperty()
          Whether the Java resource persistent attribute is a property does not change.
 java.util.Iterator<java.lang.String> typeInterfaceNames()
          Return the names of the attribute type's interfaces.
 boolean typeIsEnum()
          Return whether the attribute type is an enum.
 boolean typeIsInterface()
          Return whether the attribute type is an interface.
 boolean typeIsSubTypeOf(java.lang.String typeName)
          Return whether the attribute's type implements or extends the specified type.
 boolean typeIsVariablePrimitive()
          Return whether the attribute's type is a "variable" primitive type (i.e.
 java.util.ListIterator<java.lang.String> typeSuperclassNames()
          Return the names of the attribute type's superclasses.
 java.util.ListIterator<java.lang.String> typeTypeArgumentNames()
          Return the names of the attribute type's type arguments.
 int typeTypeArgumentNamesSize()
           
 
Methods inherited from interface org.eclipse.jpt.core.resource.java.JavaResourcePersistentMember
addSupportingAnnotation, addSupportingAnnotation, getMappingAnnotation, getMappingAnnotation, getNameTextRange, getNonNullSupportingAnnotation, getSupportingAnnotation, isFor, isPersistable, isPersisted, mappingAnnotations, mappingAnnotationsSize, moveSupportingAnnotation, removeSupportingAnnotation, removeSupportingAnnotation, resolveTypes, setMappingAnnotation, supportingAnnotations, supportingAnnotations, supportingAnnotationsSize
 
Methods inherited from interface org.eclipse.jpt.core.resource.java.JavaResourceNode
getFile, getJavaResourceCompilationUnit, getRoot, getTextRange, initialize, update
 
Methods inherited from interface org.eclipse.jpt.utility.model.Model
addCollectionChangeListener, addCollectionChangeListener, addListChangeListener, addListChangeListener, addPropertyChangeListener, addPropertyChangeListener, addStateChangeListener, addTreeChangeListener, addTreeChangeListener, removeCollectionChangeListener, removeCollectionChangeListener, removeListChangeListener, removeListChangeListener, removePropertyChangeListener, removePropertyChangeListener, removeStateChangeListener, removeTreeChangeListener, removeTreeChangeListener
 

Field Detail

MODIFIERS_PROPERTY

static final java.lang.String MODIFIERS_PROPERTY
See Also:
Constant Field Values

TYPE_NAME_PROPERTY

static final java.lang.String TYPE_NAME_PROPERTY
See Also:
Constant Field Values

TYPE_IS_INTERFACE_PROPERTY

static final java.lang.String TYPE_IS_INTERFACE_PROPERTY
See Also:
Constant Field Values

TYPE_IS_ENUM_PROPERTY

static final java.lang.String TYPE_IS_ENUM_PROPERTY
See Also:
Constant Field Values

TYPE_SUPERCLASS_NAMES_COLLECTION

static final java.lang.String TYPE_SUPERCLASS_NAMES_COLLECTION
See Also:
Constant Field Values

TYPE_INTERFACE_NAMES_COLLECTION

static final java.lang.String TYPE_INTERFACE_NAMES_COLLECTION
See Also:
Constant Field Values

TYPE_TYPE_ARGUMENT_NAMES_COLLECTION

static final java.lang.String TYPE_TYPE_ARGUMENT_NAMES_COLLECTION
See Also:
Constant Field Values
Method Detail

getName

java.lang.String getName()
The Java resource persistent attribute's name does not change.


getNullMappingAnnotation

Annotation getNullMappingAnnotation(java.lang.String annotationName)
Return a null mapping annotation with the specified name. Return null if the specified annotation name is null. The corresponding AnnotationDefinition must implement #buildNullAnnotation() AnnotationDefinition#buildNullAnnotation(JavaResourcePersistentMember, org.eclipse.jpt.core.utility.jdt.Member)


isField

boolean isField()
Whether the Java resource persistent attribute is a field does not change.


isProperty

boolean isProperty()
Whether the Java resource persistent attribute is a property does not change.


hasAnyPersistenceAnnotations

boolean hasAnyPersistenceAnnotations()
Return whether the attribute has any mapping or non-mapping annotations (of course only persistence-related annotations).


getSpecifiedAccess

AccessType getSpecifiedAccess()
Return the access type explicitly specified by the javax.persistence.Access annotation. Return null if the Access annotation is not present.


typeIsSubTypeOf

boolean typeIsSubTypeOf(java.lang.String typeName)
Return whether the attribute's type implements or extends the specified type.


typeIsVariablePrimitive

boolean typeIsVariablePrimitive()
Return whether the attribute's type is a "variable" primitive type (i.e. any primitive type except 'void').


isFor

boolean isFor(MethodSignature methodSignature,
              int occurrence)
Return whether the Java resource persistent attribute is for the specified method.


getModifiers

int getModifiers()
See Also:
Modifier

getTypeName

java.lang.String getTypeName()
Return the resolved, qualified name of the attribute's type (e.g. "java.util.Collection" or "byte[]"). If the type is an array, this name will include the appropriate number of bracket pairs. This name will not include the type's generic type arguments (e.g. "java.util.Collection").

See Also:
typeTypeArgumentNames()

typeIsInterface

boolean typeIsInterface()
Return whether the attribute type is an interface.


typeIsEnum

boolean typeIsEnum()
Return whether the attribute type is an enum.


typeSuperclassNames

java.util.ListIterator<java.lang.String> typeSuperclassNames()
Return the names of the attribute type's superclasses.


typeInterfaceNames

java.util.Iterator<java.lang.String> typeInterfaceNames()
Return the names of the attribute type's interfaces.


typeTypeArgumentNames

java.util.ListIterator<java.lang.String> typeTypeArgumentNames()
Return the names of the attribute type's type arguments. The name for any argument that is an array will contain the appropriate number of bracket pairs. The names will not include any further generic type arguments.


typeTypeArgumentNamesSize

int typeTypeArgumentNamesSize()

getTypeTypeArgumentName

java.lang.String getTypeTypeArgumentName(int index)