jakarta.persistence.Id
attribute with zero-or-more jakarta.persistence.MapsId .
Can also be a single jakarta.persistence.Id with jakarta.persistence.MapsId
| Modifier and Type | Field and Description |
|---|---|
| private final EntityPersister | |
| private final IdClassEmbeddable | |
| private final NonAggregatedIdentifierMapping. | |
| private final VirtualIdEmbeddable |
| Access | Constructor and Description |
|---|---|
| public | NonAggregatedIdentifierMappingImpl(EntityPersister entityPersister, RootClass bootEntityDescriptor, String rootTableName, String[] rootTableKeyColumnNames, MappingModelCreationProcess creationProcess)
|
| entityDescriptor | back to summary |
|---|---|
| private final EntityPersister entityDescriptor | |
| idClassEmbeddable | back to summary |
|---|---|
| private final IdClassEmbeddable idClassEmbeddable | |
| identifierValueMapper | back to summary |
|---|---|
| private final NonAggregatedIdentifierMapping. | |
| virtualIdEmbeddable | back to summary |
|---|---|
| private final VirtualIdEmbeddable virtualIdEmbeddable | |
| NonAggregatedIdentifierMappingImpl | back to summary |
|---|---|
| public NonAggregatedIdentifierMappingImpl(EntityPersister entityPersister, RootClass bootEntityDescriptor, String rootTableName, String[] rootTableKeyColumnNames, MappingModelCreationProcess creationProcess) | |
| addToCacheKey | back to summary |
|---|---|
| public void addToCacheKey(MutableCacheKeyBuilder cacheKey, Object value, SharedSessionContractImplementor session) Overrides default org. Implements org. Doc from org. Add to the MutableCacheKey the values obtained disassembling the value and the hasCode generated from the disassembled value.
| |
| applySqlSelections | back to summary |
|---|---|
| public void applySqlSelections(NavigablePath navigablePath, TableGroup tableGroup, DomainResultCreationState creationState) Implements org. Doc from org. Apply SQL selections for a specific reference to this ModelPart outside the domain query's root select clause.
| |
| applySqlSelections | back to summary |
|---|---|
| public void applySqlSelections(NavigablePath navigablePath, TableGroup tableGroup, DomainResultCreationState creationState, BiConsumer<SqlSelection, JdbcMapping> selectionConsumer) Implements org. Doc from org. Apply SQL selections for a specific reference to this ModelPart outside the domain query's root select clause.
| |
| breakDownJdbcValues | back to summary |
|---|---|
| public <X, Y> int breakDownJdbcValues(Object domainValue, int offset, X x, Y y, ModelPart. Overrides default org. Implements org. Doc from org. Breaks down the domain value to its constituent JDBC values.
Think of it as breaking the multi-dimensional array into a visitable flat array.
Additionally, it passes through the values
| |
| createDomainResult | back to summary |
|---|---|
| public <T> DomainResult Overrides org. Implements org. Doc from org. Create a DomainResult for a specific reference to this ModelPart.
| |
| disassemble | back to summary |
|---|---|
| public Object disassemble(Object value, SharedSessionContractImplementor session) Overrides default org. Implements org. Doc from org. Breaks down a value of
Generally speaking, this is the form in which entity state is kept relative to a
Session via
@Entity class Person {
@Id Integer id;
@Embedded Name name;
int age;
}
@Embeddable class Name {
String familiarName;
String familyName;
}
At the top level, we would want to disassemble a
Person( id=1, name=Name( 'Steve', 'Ebersole' ), 28 ) this disassemble would result in a multidimensional array:
[ ["Steve", "Ebersole"], 28 ] Note that the identifier is not part of this disassembled state. Note also how the embedded value results in a sub-array.
| |
| forEachJdbcValue | back to summary |
|---|---|
| public <X, Y> int forEachJdbcValue(Object value, int offset, X x, Y y, Bindable. Overrides org. Overrides default org. Doc from org. Visit each constituent JDBC value extracted from the entity instance itself.
Short-hand form of calling
| |
| generateFetch | back to summary |
|---|---|
| public Fetch generateFetch(FetchParent fetchParent, NavigablePath fetchablePath, FetchTiming fetchTiming, boolean selected, String resultVariable, DomainResultCreationState creationState) Overrides org. Implements org. Doc from org. Generates a Fetch of this fetchable
| |
| getAttributeName | back to summary |
|---|---|
| public String getAttributeName() Implements org. Doc from org. The name of the attribute defining the id, if one
| |
| getFetchable | back to summary |
|---|---|
| public Fetchable getFetchable(int position) Overrides default org.
| |
| getFetchableName | back to summary |
|---|---|
| public String getFetchableName() Implements org. Doc from org. The name of the fetchable. This is the part's "local name".
| |
| getIdClassEmbeddable | back to summary |
|---|---|
| public IdClassEmbeddable getIdClassEmbeddable() Implements org. Doc from org. The id-class representation of this id mapping
| |
| getIdentifier | back to summary |
|---|---|
| public Object getIdentifier(Object entity) Implements org. Doc from org. Extract the identifier from an instance of the entity
| |
| getIdentifierValueMapper | back to summary |
|---|---|
| public NonAggregatedIdentifierMapping. Implements org. Doc from org. The id-class, if there is one, otherwise the virtual-id.
| |
| getMappedIdEmbeddableTypeDescriptor | back to summary |
|---|---|
| public EmbeddableMappingType getMappedIdEmbeddableTypeDescriptor() Implements org. Doc from org. Returns the embeddable type descriptor of the id-class, if there is one, otherwise the one of the virtual embeddable mapping type.
| |
| getMappedType | back to summary |
|---|---|
| public EmbeddableMappingType getMappedType() Overrides org. Overrides default org. Implements org. Doc from org. Descriptor for the type of this mapping
| |
| getNature | back to summary |
|---|---|
| public EntityIdentifierMapping. Implements org.
| |
| getNumberOfFetchables | back to summary |
|---|---|
| public int getNumberOfFetchables() Overrides default org. Doc from org. The number of fetchables in the container
| |
| getPartMappingType | back to summary |
|---|---|
| public EmbeddableMappingType getPartMappingType() Implements org. Doc from org. The type for this part.
| |
| getSqlAliasStem | back to summary |
|---|---|
| public String getSqlAliasStem() Implements org. Doc from org. Get the "stem" used as the base for generating SQL table aliases for table references that are part of the TableGroup being generated Note that this is a metadata-ive value. It is only ever used internal to the producer producing its TableGroup.
| |
| getVirtualIdEmbeddable | back to summary |
|---|---|
| public VirtualIdEmbeddable getVirtualIdEmbeddable() Implements org. Doc from org. The virtual-id representation of this id mapping
| |
| hasContainingClass | back to summary |
|---|---|
| public boolean hasContainingClass() Overrides org. Implements org. Doc from org. Does the identifier have a corresponding EmbeddableId or IdClass?
| |
| setIdentifier | back to summary |
|---|---|
| public void setIdentifier(Object entity, Object id, SharedSessionContractImplementor session) Implements org. Doc from org. Inject an identifier value into an instance of the entity
| |
| toSqlExpression | back to summary |
|---|---|
| public SqlTuple toSqlExpression(TableGroup tableGroup, Clause clause, SqmToSqlAstConverter walker, SqlAstCreationState sqlAstCreationState) Overrides org. Implements org.
| |