Class EmbeddedAttributeMapping
java.lang.Object
org.hibernate.metamodel.mapping.internal.AbstractAttributeMapping
org.hibernate.metamodel.mapping.internal.AbstractStateArrayContributorMapping
org.hibernate.metamodel.mapping.internal.AbstractSingularAttributeMapping
org.hibernate.metamodel.mapping.internal.EmbeddedAttributeMapping
- All Implemented Interfaces:
AttributeMapping,Bindable,EmbeddableValuedModelPart,JdbcMappingContainer,MappingModelExpressible,ModelPart,ModelPartContainer,OwnedValuedModelPart,PropertyBasedMapping,SelectableMappings,SingularAttributeMapping,ValuedModelPart,ValueMapping,TableGroupJoinProducer,TableGroupProducer,DatabaseSnapshotContributor,EmbeddableValuedFetchable,Fetchable,FetchableContainer,FetchOptions,FetchStyleAccess,FetchTimingAccess,JavaTypedExpressible,MutabilityPlanExposer
- Direct Known Subclasses:
InverseNonAggregatedIdentifierMapping,VirtualEmbeddedAttributeMapping
public class EmbeddedAttributeMapping
extends AbstractSingularAttributeMapping
implements EmbeddableValuedFetchable, Fetchable
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.hibernate.metamodel.mapping.Bindable
Bindable.JdbcValuesBiConsumer<X,Y>, Bindable.JdbcValuesConsumer Nested classes/interfaces inherited from interface org.hibernate.metamodel.mapping.ModelPart
ModelPart.JdbcValueBiConsumer<X,Y>, ModelPart.JdbcValueConsumer -
Constructor Summary
ConstructorsConstructorDescriptionEmbeddedAttributeMapping(String name, NavigableRole navigableRole, int stateArrayPosition, int fetchableIndex, String tableExpression, AttributeMetadata attributeMetadata, String parentInjectionAttributeName, FetchTiming mappedFetchTiming, FetchStyle mappedFetchStyle, EmbeddableMappingType embeddableMappingType, ManagedMappingType declaringType, PropertyAccess propertyAccess) EmbeddedAttributeMapping(String name, NavigableRole navigableRole, int stateArrayPosition, int fetchableIndex, String tableExpression, AttributeMetadata attributeMetadata, PropertyAccess parentInjectionAttributePropertyAccess, FetchTiming mappedFetchTiming, FetchStyle mappedFetchStyle, EmbeddableMappingType embeddableMappingType, ManagedMappingType declaringType, PropertyAccess propertyAccess) -
Method Summary
Modifier and TypeMethodDescriptionvoidapplySqlSelections(NavigablePath navigablePath, TableGroup tableGroup, DomainResultCreationState creationState) Apply SQL selections for a specific reference to this ModelPart outside the domain query's root select clause.voidapplySqlSelections(NavigablePath navigablePath, TableGroup tableGroup, DomainResultCreationState creationState, BiConsumer<SqlSelection, JdbcMapping> selectionConsumer) Apply SQL selections for a specific reference to this ModelPart outside the domain query's root select clause.A utility method to avoid casting explicitly to EmbeddedAttributeMappingintbooleancontainsTableReference(String tableExpression) <T> DomainResult<T> createDomainResult(NavigablePath navigablePath, TableGroup tableGroup, String resultVariable, DomainResultCreationState creationState) Create a DomainResult for a specific reference to this ModelPart.createRootTableGroupJoin(NavigablePath navigablePath, TableGroup lhs, @Nullable String explicitSourceAlias, @Nullable SqlAliasBase explicitSqlAliasBase, @Nullable SqlAstJoinType sqlAstJoinType, boolean fetched, @Nullable Consumer<Predicate> predicateConsumer, SqlAstCreationState creationState) Create the "join", but return a TableGroup.createTableGroupJoin(NavigablePath navigablePath, TableGroup lhs, @Nullable String explicitSourceAlias, @Nullable SqlAliasBase explicitSqlAliasBase, @Nullable SqlAstJoinType requestedJoinType, boolean fetched, boolean addsPredicate, SqlAstCreationState creationState) Create a TableGroupJoin.generateFetch(FetchParent fetchParent, NavigablePath fetchablePath, FetchTiming fetchTiming, boolean selected, String resultVariable, DomainResultCreationState creationState) Generates a Fetch of this fetchableThe table which contains the columns mapped by this valueDescriptor for the type of this mappingGet the "stem" used as the base for generating SQL table aliases for table references that are part of the TableGroup being generatedbooleanbooleantoSqlExpression(TableGroup tableGroup, Clause clause, SqmToSqlAstConverter walker, SqlAstCreationState sqlAstCreationState) toString()Methods inherited from class org.hibernate.metamodel.mapping.internal.AbstractSingularAttributeMapping
getGeneratorMethods inherited from class org.hibernate.metamodel.mapping.internal.AbstractStateArrayContributorMapping
getFetchableName, getMappedFetchOptions, getStyle, getTimingMethods inherited from class org.hibernate.metamodel.mapping.internal.AbstractAttributeMapping
getAttributeMetadata, getAttributeName, getDeclaringType, getFetchableKey, getJavaType, getPartMappingType, getPropertyAccess, getStateArrayPositionMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.hibernate.metamodel.mapping.AttributeMapping
asAttributeMapping, asPluralAttributeMapping, findContainingEntityMapping, getAttributeMetadata, getAttributeName, getDeclaringType, getExposedMutabilityPlan, getPartName, getPropertyAccess, getStateArrayPosition, getValue, isPluralAttributeMapping, setValueMethods inherited from interface org.hibernate.metamodel.mapping.Bindable
forEachDisassembledJdbcValue, forEachDisassembledJdbcValue, forEachDisassembledJdbcValue, forEachJdbcType, forEachJdbcValue, forEachJdbcValue, forEachJdbcValueMethods inherited from interface org.hibernate.sql.results.graph.DatabaseSnapshotContributor
createSnapshotDomainResultMethods inherited from interface org.hibernate.sql.results.graph.embeddable.EmbeddableValuedFetchable
getDefaultSqlAstJoinType, isSimpleJoinPredicateMethods inherited from interface org.hibernate.metamodel.mapping.EmbeddableValuedModelPart
addToCacheKey, breakDownJdbcValues, decompose, disassemble, findSubPart, forEachDisassembledJdbcValue, forEachInsertable, forEachJdbcType, forEachJdbcValue, forEachSelectable, forEachSubPart, forEachUpdatable, getFetchable, getJavaType, getJdbcMapping, getJdbcTypeCount, getNumberOfFetchables, getSelectable, getSelectableIndex, hasPartitionedSelectionMapping, visitSubPartsMethods inherited from interface org.hibernate.sql.results.graph.Fetchable
getFetchableKey, getFetchableName, getMappedFetchOptions, incrementFetchDepth, resolveCircularFetchMethods inherited from interface org.hibernate.sql.results.graph.FetchableContainer
getKeyFetchable, getNumberOfFetchableKeys, getNumberOfKeyFetchables, visitFetchables, visitFetchables, visitFetchables, visitKeyFetchables, visitKeyFetchables, visitKeyFetchablesMethods inherited from interface org.hibernate.type.descriptor.java.JavaTypedExpressible
addToCacheKeyMethods inherited from interface org.hibernate.metamodel.mapping.ModelPart
areEqual, asBasicValuedModelPart, asEntityMappingType, breakDownJdbcValues, decompose, getPartMappingType, isEntityIdentifierMapping, isVirtualMethods inherited from interface org.hibernate.metamodel.mapping.ModelPartContainer
findByPath, findByPath, forEachSubPartMethods inherited from interface org.hibernate.sql.ast.tree.from.TableGroupJoinProducer
determineSqlJoinTypeMethods inherited from interface org.hibernate.metamodel.mapping.ValuedModelPart
forEachNonFormula, forEachSelectable, getSingleJdbcMappingMethods inherited from interface org.hibernate.metamodel.mapping.ValueMapping
getExpressibleJavaType, treatAs
-
Constructor Details
-
Method Details
-
getMappedType
Description copied from interface:ValueMappingDescriptor for the type of this mapping- Specified by:
getMappedTypein interfaceEmbeddableValuedModelPart- Specified by:
getMappedTypein interfaceValueMapping
-
getEmbeddableTypeDescriptor
- Specified by:
getEmbeddableTypeDescriptorin interfaceEmbeddableValuedModelPart
-
getContainingTableExpression
Description copied from interface:ValuedModelPartThe table which contains the columns mapped by this value- Specified by:
getContainingTableExpressionin interfaceValuedModelPart
-
getParentInjectionAttributePropertyAccess
- Specified by:
getParentInjectionAttributePropertyAccessin interfaceEmbeddableValuedModelPart- See Also:
-
toSqlExpression
public SqlTuple toSqlExpression(TableGroup tableGroup, Clause clause, SqmToSqlAstConverter walker, SqlAstCreationState sqlAstCreationState) - Specified by:
toSqlExpressionin interfaceEmbeddableValuedModelPart
-
getSqlAliasStem
Description copied from interface:TableGroupProducerGet the "stem" used as the base for generating SQL table aliases for table references that are part of the TableGroup being generatedNote that this is a metadata-ive value. It is only ever used internal to the producer producing its TableGroup.
- Specified by:
getSqlAliasStemin interfaceTableGroupProducer- See Also:
-
toString
-
asEmbeddedAttributeMapping
Description copied from interface:AttributeMappingA utility method to avoid casting explicitly to EmbeddedAttributeMapping- Specified by:
asEmbeddedAttributeMappingin interfaceAttributeMapping- Returns:
- EmbeddedAttributeMapping if this is an instance of EmbeddedAttributeMapping otherwise
null
-
isEmbeddedAttributeMapping
public boolean isEmbeddedAttributeMapping()- Specified by:
isEmbeddedAttributeMappingin interfaceAttributeMapping
-
isSelectable
public boolean isSelectable()- Specified by:
isSelectablein interfaceFetchable
-
containsTableReference
- Specified by:
containsTableReferencein interfaceTableGroupProducer
-
compare
- Specified by:
comparein interfaceAttributeMapping
-