Top Description Fields Constructors Methods
org.hibernate.metamodel.mapping.internal

public Class VirtualIdEmbeddable

extends AbstractEmbeddableMapping
implements IdentifierValueMapper
Class Inheritance
All Implemented Interfaces
org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper, org.hibernate.metamodel.mapping.EmbeddableMappingType, org.hibernate.metamodel.mapping.SelectableMappings, org.hibernate.metamodel.mapping.ManagedMappingType, org.hibernate.sql.results.graph.FetchableContainer, org.hibernate.metamodel.mapping.ModelPartContainer, org.hibernate.metamodel.mapping.ModelPart, org.hibernate.metamodel.mapping.MappingModelExpressible, org.hibernate.metamodel.mapping.Bindable, org.hibernate.metamodel.mapping.JdbcMappingContainer, org.hibernate.metamodel.mapping.MappingType
Imports
org.hibernate.engine.spi.SharedSessionContractImplementor, org.hibernate.mapping.Component, org.hibernate.metamodel.mapping.AttributeMapping, .AttributeMappingsList, .EmbeddableMappingType, .EmbeddableValuedModelPart, .EntityMappingType, .NonAggregatedIdentifierMapping, .SelectableMappings, org.hibernate.metamodel.model.domain.NavigableRole, org.hibernate.persister.entity.EntityPersister, org.hibernate.property.access.spi.Getter, org.hibernate.spi.NavigablePath, org.hibernate.sql.ast.tree.from.TableGroup, .TableGroupProducer, org.hibernate.sql.results.graph.DomainResult, .DomainResultCreationState, org.hibernate.type.AnyType, .CollectionType, .CompositeType, org.hibernate.type.spi.CompositeTypeImplementor

Embeddable describing the virtual-id aspect of a non-aggregated composite id

Field Summary

Modifier and TypeField and Description
private final NonAggregatedIdentifierMapping
private final VirtualIdRepresentationStrategy
Inherited from org.hibernate.metamodel.mapping.internal.AbstractEmbeddableMapping:
attributeMappingsselectableMappings

Constructor Summary

AccessConstructor and Description
public
VirtualIdEmbeddable(Component virtualIdSource, NonAggregatedIdentifierMapping idMapping, EntityPersister identifiedEntityMapping, String rootTableExpression, String[] rootTableKeyColumnNames, MappingModelCreationProcess creationProcess)

public
VirtualIdEmbeddable(EmbeddedAttributeMapping valueMapping, TableGroupProducer declaringTableGroupProducer, SelectableMappings selectableMappings, VirtualIdEmbeddable inverseMappingType, MappingModelCreationProcess creationProcess)

Method Summary

Modifier and TypeMethod and Description
public int
public <T> DomainResult<T>
createDomainResult(NavigablePath navigablePath, TableGroup tableGroup, String resultVariable, DomainResultCreationState creationState)

Implements org.hibernate.metamodel.mapping.EmbeddableMappingType.createDomainResult.

Create a DomainResult for a specific reference to this ModelPart.
public EmbeddableMappingType
public <X, Y> int
decompose(Object domainValue, int offset, X x, Y y, ModelPart.JdbcValueBiConsumer<X, Y> valueConsumer, SharedSessionContractImplementor session)

Overrides default org.hibernate.metamodel.mapping.ModelPart.decompose.

Similar to breakDownJdbcValues(Object, int, Object, Object, JdbcValueBiConsumer, SharedSessionContractImplementor), but this method is supposed to be used for decomposing values for assignment expressions.
public EntityMappingType
private boolean
finishInitialization(Component bootDescriptor, CompositeType compositeType, String rootTableExpression, String[] rootTableKeyColumnNames, MappingModelCreationProcess creationProcess)

public EmbeddableValuedModelPart
public EmbeddableValuedModelPart
public Object
getIdentifier(Object entity, SharedSessionContractImplementor session)

Implements org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.getIdentifier.

Extract the identifier out of the given entity, returning the mapper's representation
public NavigableRole
public String
getPartName()

Implements org.hibernate.metamodel.mapping.ModelPart.getPartName.

The local part name, which is generally the unqualified role name
public VirtualIdRepresentationStrategy
public boolean
public void
setIdentifier(Object entity, Object id, SharedSessionContractImplementor session)

Implements org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.setIdentifier.

Extract the identifier out of the given entity, returning the mapper's representation
Inherited from org.hibernate.metamodel.mapping.internal.AbstractEmbeddableMapping:
addAttributeaddToCacheKeybreakDownJdbcValuesdisassemblefindAttributeMappingfindSubPartfinishInitializationforEachAttributeMappingforEachAttributeMappingforEachDisassembledJdbcValueforEachJdbcTypeforEachJdbcValueforEachSelectableforEachSelectableforEachSubPartgetAttributeMappinggetAttributeMappingsgetFetchablegetJdbcMappinggetJdbcTypeCountgetMappedJavaTypegetNumberOfAttributeMappingsgetNumberOfFetchablesgetSelectablegetSelectableMappingsgetValuesinitColumnMappingsinverseInitializeCallbacksetValuesvisitFetchablesvisitFetchablesvisitSubParts

Field Detail

idMappingback to summary
private final NonAggregatedIdentifierMapping idMapping
representationStrategyback to summary
private final VirtualIdRepresentationStrategy representationStrategy

Constructor Detail

VirtualIdEmbeddableback to summary
public VirtualIdEmbeddable(Component virtualIdSource, NonAggregatedIdentifierMapping idMapping, EntityPersister identifiedEntityMapping, String rootTableExpression, String[] rootTableKeyColumnNames, MappingModelCreationProcess creationProcess)
VirtualIdEmbeddableback to summary
public VirtualIdEmbeddable(EmbeddedAttributeMapping valueMapping, TableGroupProducer declaringTableGroupProducer, SelectableMappings selectableMappings, VirtualIdEmbeddable inverseMappingType, MappingModelCreationProcess creationProcess)

Method Detail

compareback to summary
public int compare(Object value1, Object value2)

Overrides default org.hibernate.metamodel.mapping.EmbeddableMappingType.compare.

Annotations
@Override
createDomainResultback to summary
public <T> DomainResult<T> createDomainResult(NavigablePath navigablePath, TableGroup tableGroup, String resultVariable, DomainResultCreationState creationState)

Implements org.hibernate.metamodel.mapping.EmbeddableMappingType.createDomainResult.

Doc from org.hibernate.metamodel.mapping.ModelPart.createDomainResult.

Create a DomainResult for a specific reference to this ModelPart.

Annotations
@Override
createInverseMappingTypeback to summary
public EmbeddableMappingType createInverseMappingType(EmbeddedAttributeMapping valueMapping, TableGroupProducer declaringTableGroupProducer, SelectableMappings selectableMappings, MappingModelCreationProcess creationProcess)

Implements org.hibernate.metamodel.mapping.EmbeddableMappingType.createInverseMappingType.

Annotations
@Override
decomposeback to summary
public <X, Y> int decompose(Object domainValue, int offset, X x, Y y, ModelPart.JdbcValueBiConsumer<X, Y> valueConsumer, SharedSessionContractImplementor session)

Overrides default org.hibernate.metamodel.mapping.ModelPart.decompose.

Doc from org.hibernate.metamodel.mapping.ModelPart.decompose.

Similar to breakDownJdbcValues(Object, int, Object, Object, JdbcValueBiConsumer, SharedSessionContractImplementor), but this method is supposed to be used for decomposing values for assignment expressions. Returns the amount of jdbc types that have been visited.

Annotations
@Override
findContainingEntityMappingback to summary
public EntityMappingType findContainingEntityMapping()

Implements org.hibernate.metamodel.mapping.ModelPart.findContainingEntityMapping.

Annotations
@Override
finishInitializationback to summary
private boolean finishInitialization(Component bootDescriptor, CompositeType compositeType, String rootTableExpression, String[] rootTableKeyColumnNames, MappingModelCreationProcess creationProcess)
getEmbeddedPartback to summary
public EmbeddableValuedModelPart getEmbeddedPart()

Implements org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.getEmbeddedPart.

Annotations
@Override
getEmbeddedValueMappingback to summary
public EmbeddableValuedModelPart getEmbeddedValueMapping()

Implements org.hibernate.metamodel.mapping.EmbeddableMappingType.getEmbeddedValueMapping.

Annotations
@Override
getIdentifierback to summary
public Object getIdentifier(Object entity, SharedSessionContractImplementor session)

Implements org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.getIdentifier.

Doc from org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.getIdentifier.

Extract the identifier out of the given entity, returning the mapper's representation

Annotations
@Override
getNavigableRoleback to summary
public NavigableRole getNavigableRole()

Implements org.hibernate.metamodel.mapping.ModelPart.getNavigableRole.

Annotations
@Override
getPartNameback to summary
public String getPartName()

Implements org.hibernate.metamodel.mapping.ModelPart.getPartName.

Doc from org.hibernate.metamodel.mapping.ModelPart.getPartName.

The local part name, which is generally the unqualified role name

Annotations
@Override
getRepresentationStrategyback to summary
public VirtualIdRepresentationStrategy getRepresentationStrategy()

Implements org.hibernate.metamodel.mapping.EmbeddableMappingType.getRepresentationStrategy.

Annotations
@Override
isCreateEmptyCompositesEnabledback to summary
public boolean isCreateEmptyCompositesEnabled()

Implements org.hibernate.metamodel.mapping.EmbeddableMappingType.isCreateEmptyCompositesEnabled.

Annotations
@Override
setIdentifierback to summary
public void setIdentifier(Object entity, Object id, SharedSessionContractImplementor session)

Implements org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.setIdentifier.

Doc from org.hibernate.metamodel.mapping.NonAggregatedIdentifierMapping.IdentifierValueMapper.setIdentifier.

Extract the identifier out of the given entity, returning the mapper's representation

Annotations
@Override