X
- The represented entity or mapped superclass type.public abstract class IdentifiableTypeImpl<X> extends ManagedTypeImpl<X> implements javax.persistence.metamodel.IdentifiableType<X>
Purpose: Provides the implementation for the Entity interface of the JPA 2.0 Metamodel API (part of the JSR-317 EJB 3.1 Criteria API)
Description: Instances of the type IdentifiableType represent entity or mapped superclass types.
javax.persistence.metamodel.Entity
,
Serialized FormModifier and Type | Method and Description |
---|---|
<Y> javax.persistence.metamodel.SingularAttribute<X,Y> |
getDeclaredId(java.lang.Class<Y> type)
Return the attribute that corresponds to the id attribute
declared by the entity or mapped superclass.
|
<Y> javax.persistence.metamodel.SingularAttribute<X,Y> |
getDeclaredVersion(java.lang.Class<Y> type)
Return the attribute that corresponds to the version
attribute declared by the entity or mapped superclass.
|
<Y> javax.persistence.metamodel.SingularAttribute<? super X,Y> |
getId(java.lang.Class<Y> type)
Return the attribute that corresponds to the id attribute of
the entity or mapped superclass.
|
java.util.Set<javax.persistence.metamodel.SingularAttribute<? super X,?>> |
getIdClassAttributes()
Return the attributes corresponding to the id class of the
identifiable type.
|
javax.persistence.metamodel.Type<?> |
getIdType()
Return the type that represents the type of the id.
|
javax.persistence.metamodel.IdentifiableType<? super X> |
getSupertype()
Return the identifiable type that corresponds to the most
specific mapped superclass or entity extended by the entity
or mapped superclass.
|
<Y> javax.persistence.metamodel.SingularAttribute<? super X,Y> |
getVersion(java.lang.Class<Y> type)
Return the attribute that corresponds to the version
attribute of the entity or mapped superclass.
|
boolean |
hasSingleIdAttribute()
Whether or not the identifiable type has an id attribute.
|
boolean |
hasVersionAttribute()
Whether or not the identifiable type has a version attribute.
|
getAttribute, getAttributes, getCollection, getCollection, getDeclaredAttribute, getDeclaredAttributes, getDeclaredCollection, getDeclaredCollection, getDeclaredList, getDeclaredList, getDeclaredMap, getDeclaredMap, getDeclaredPluralAttributes, getDeclaredSet, getDeclaredSet, getDeclaredSingularAttribute, getDeclaredSingularAttribute, getDeclaredSingularAttributes, getDescriptor, getList, getList, getMap, getMap, getPluralAttributes, getSet, getSet, getSingularAttribute, getSingularAttribute, getSingularAttributes
getJavaType, getJavaType, getJavaTypeName, isEntity, isMappedSuperclass, toString
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
getAttribute, getAttributes, getCollection, getCollection, getDeclaredAttribute, getDeclaredAttributes, getDeclaredCollection, getDeclaredCollection, getDeclaredList, getDeclaredList, getDeclaredMap, getDeclaredMap, getDeclaredPluralAttributes, getDeclaredSet, getDeclaredSet, getDeclaredSingularAttribute, getDeclaredSingularAttribute, getDeclaredSingularAttributes, getList, getList, getMap, getMap, getPluralAttributes, getSet, getSet, getSingularAttribute, getSingularAttribute, getSingularAttributes
public <Y> javax.persistence.metamodel.SingularAttribute<X,Y> getDeclaredId(java.lang.Class<Y> type)
getDeclaredId
in interface javax.persistence.metamodel.IdentifiableType<X>
type
- the type of the represented declared id attributejava.lang.IllegalArgumentException
- if id attribute of the given
type is not declared in the identifiable type or if
the identifiable type has an id classpublic <Y> javax.persistence.metamodel.SingularAttribute<X,Y> getDeclaredVersion(java.lang.Class<Y> type)
getDeclaredVersion
in interface javax.persistence.metamodel.IdentifiableType<X>
type
- the type of the represented declared version
attributejava.lang.IllegalArgumentException
- if version attribute of the
type is not declared in the identifiable typepublic java.util.Set<javax.persistence.metamodel.SingularAttribute<? super X,?>> getIdClassAttributes()
getIdClassAttributes
in interface javax.persistence.metamodel.IdentifiableType<X>
java.lang.IllegalArgumentException
- if the identifiable type
does not have an id classpublic <Y> javax.persistence.metamodel.SingularAttribute<? super X,Y> getId(java.lang.Class<Y> type)
getId
in interface javax.persistence.metamodel.IdentifiableType<X>
type
- the type of the represented id attributejava.lang.IllegalArgumentException
- if id attribute of the given
type is not present in the identifiable type or if
the identifiable type has an id classpublic javax.persistence.metamodel.Type<?> getIdType()
getIdType
in interface javax.persistence.metamodel.IdentifiableType<X>
public javax.persistence.metamodel.IdentifiableType<? super X> getSupertype()
getSupertype
in interface javax.persistence.metamodel.IdentifiableType<X>
public <Y> javax.persistence.metamodel.SingularAttribute<? super X,Y> getVersion(java.lang.Class<Y> type)
getVersion
in interface javax.persistence.metamodel.IdentifiableType<X>
type
- the type of the represented version attributejava.lang.IllegalArgumentException
- if version attribute of the
given type is not present in the identifiable typepublic boolean hasSingleIdAttribute()
hasSingleIdAttribute
in interface javax.persistence.metamodel.IdentifiableType<X>
public boolean hasVersionAttribute()
hasVersionAttribute
in interface javax.persistence.metamodel.IdentifiableType<X>
EclipseLink 2.6.3, "build v20160428-59c81c5" API Reference