Class AnnotatedJoinColumn
java.lang.Object
org.hibernate.boot.model.internal.AnnotatedColumn
org.hibernate.boot.model.internal.AnnotatedJoinColumn
An element of a join condition, logically representing a
JoinColumn
annotation, but not
every instance corresponds to an explicit annotation in the
Java code.
There's no exact analog of this class in the mapping model,
so some information is lost when it's transformed into a
Column
.
-
Field Summary
Fields inherited from class org.hibernate.boot.model.internal.AnnotatedColumn
sqlType
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
addColumnBinding
(SimpleValue value) void
addDefaultJoinColumnName
(PersistentClass referencedEntity, String logicalReferencedColumn) void
applyJoinAnnotation
(JoinColumn joinColumn, String defaultName) static AnnotatedJoinColumn
buildInheritanceJoinColumn
(PrimaryKeyJoinColumn primaryKeyJoinColumn, JoinColumn joinColumn, Value identifier, AnnotatedJoinColumns parent, MetadataBuildingContext context) Called forInheritanceType.JOINED
entities.static AnnotatedJoinColumn
buildJoinFormula
(JoinFormula joinFormula, AnnotatedJoinColumns parent) static void
checkIfJoinColumn
(Object columns, PropertyHolder holder, PropertyData property) void
copyReferencedStructureAndCreateDefaultJoinColumns
(PersistentClass referencedEntity, SimpleValue referencedValue, SimpleValue value) ThereferencedColumnName
.boolean
void
linkValueUsingAColumnCopy
(Column column, SimpleValue value) used for mappedBy casesvoid
linkValueUsingDefaultColumnNaming
(int columnIndex, Column referencedColumn, PersistentClass referencedEntity, SimpleValue value) void
linkValueUsingDefaultColumnNaming
(Column referencedColumn, PersistentClass referencedEntity, SimpleValue value) void
Called to apply column definitions from the referenced FK column to this column.void
redefineColumnName
(String columnName, String propertyName, boolean applyNamingStrategy) void
setParent
(AnnotatedColumns parent) void
setParent
(AnnotatedJoinColumns parent) void
setReferencedColumn
(String referencedColumn) toString()
Methods inherited from class org.hibernate.boot.model.internal.AnnotatedColumn
addCheckConstraint, addIndex, bind, buildColumnFromAnnotation, buildColumnFromNoAnnotation, buildColumnOrFormulaFromAnnotation, buildColumnsFromAnnotations, buildColumnsFromAnnotations, buildColumnsOrFormulaFromAnnotation, buildFormulaFromAnnotation, forceNotNull, getArrayLength, getDefaultValue, getExplicitTableName, getGeneratedAs, getLength, getLogicalColumnName, getMappingColumn, getName, getPrecision, getScale, getSqlType, initMappingColumn, isFormula, isImplicit, isInsertable, isNameDeferred, isNullable, isUnique, isUpdatable, linkWithAggregateValue, linkWithValue, setArrayLength, setDefaultValue, setExplicitTableName, setFormula, setImplicit, setInsertable, setLength, setLogicalColumnName, setMappingColumn, setNullable, setPrecision, setScale, setSqlType, setTemporalPrecision, setUnique, setUpdatable
-
Method Details
-
setReferencedColumn
-
getReferencedColumn
ThereferencedColumnName
. -
isReferenceImplicit
public boolean isReferenceImplicit()- Returns:
- true if the
@JoinColumn
annotation did not specify thereferencedColumnName
.
-
buildJoinFormula
public static AnnotatedJoinColumn buildJoinFormula(JoinFormula joinFormula, AnnotatedJoinColumns parent) -
applyJoinAnnotation
-
buildInheritanceJoinColumn
public static AnnotatedJoinColumn buildInheritanceJoinColumn(PrimaryKeyJoinColumn primaryKeyJoinColumn, JoinColumn joinColumn, Value identifier, AnnotatedJoinColumns parent, MetadataBuildingContext context) Called forInheritanceType.JOINED
entities. -
checkIfJoinColumn
-
copyReferencedStructureAndCreateDefaultJoinColumns
public void copyReferencedStructureAndCreateDefaultJoinColumns(PersistentClass referencedEntity, SimpleValue referencedValue, SimpleValue value) -
linkValueUsingDefaultColumnNaming
public void linkValueUsingDefaultColumnNaming(Column referencedColumn, PersistentClass referencedEntity, SimpleValue value) -
linkValueUsingDefaultColumnNaming
public void linkValueUsingDefaultColumnNaming(int columnIndex, Column referencedColumn, PersistentClass referencedEntity, SimpleValue value) -
addDefaultJoinColumnName
public void addDefaultJoinColumnName(PersistentClass referencedEntity, String logicalReferencedColumn) -
linkValueUsingAColumnCopy
used for mappedBy cases -
addColumnBinding
- Overrides:
addColumnBinding
in classAnnotatedColumn
-
overrideFromReferencedColumnIfNecessary
Called to apply column definitions from the referenced FK column to this column.- Parameters:
column
- the referenced column.
-
redefineColumnName
- Overrides:
redefineColumnName
in classAnnotatedColumn
-
toString
- Overrides:
toString
in classAnnotatedColumn
-
getParent
- Overrides:
getParent
in classAnnotatedColumn
-
setParent
- Overrides:
setParent
in classAnnotatedColumn
-
setParent
-