public interface IMapping extends java.lang.Comparable<IMapping>
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.
IManagedType| Modifier and Type | Method and Description |
|---|---|
int |
getMappingType()
Returns the type of this mapping.
|
java.lang.String |
getName()
Returns the name of the persistence property represented by this mapping.
|
IManagedType |
getParent()
Returns the parent managed type owning this mapping.
|
IType |
getType()
Returns the type of this mapping.
|
ITypeDeclaration |
getTypeDeclaration()
Returns the declaration of the Java class, which gives the information about type parameters,
dimensionality, etc.
|
boolean |
hasAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
Determines whether the given annotation is present on this type.
|
boolean |
isCollection()
Determines whether this
IMapping is a collection type mapping. |
boolean |
isEmbeddable()
Determines whether this
IMapping is an embeddable type mapping. |
boolean |
isProperty()
Determines whether this
IMapping is a property type mapping. |
boolean |
isRelationship()
Determines whether this
IMapping is a relationship type mapping. |
boolean |
isTransient()
Determines whether this
IMapping is a transient mapping. |
int getMappingType()
IMappingType when the provider only
supports generic JPAjava.lang.String getName()
IManagedType getParent()
IType getType()
@OneToMany
private Collection<Employee> employees;
"Employee" is the type. To retrieve Collection, getTypeDeclaration()
needs to be used, its type will be Collection and it's generic type will be
Employee.
ITypeDeclaration getTypeDeclaration()
@OneToMany
private Collection<Employee> employees;
"Collection<Employee>" is the type declaration.
boolean hasAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotationType)
annotationType - The class of the annotationtrue if the annotation is defined on this type; false
otherwiseboolean isCollection()
IMapping is a collection type mapping.true if this IMapping is a collection mapping;
false otherwiseboolean isEmbeddable()
IMapping is an embeddable type mapping.true if this IMapping is an embeddable mapping;
false otherwiseboolean isProperty()
IMapping is a property type mapping.true if this IMapping is a property mapping; false
otherwiseboolean isRelationship()
IMapping is a relationship type mapping.true if this IMapping is a relationship mapping;
false otherwise