Top Description Inners Fields Constructors Methods
org.hibernate.mapping

public Class Component

extends SimpleValue
implements MetaAttributable, SortableValue
Class Inheritance
All Implemented Interfaces
org.hibernate.mapping.SortableValue, org.hibernate.mapping.MetaAttributable
Imports
java.lang.reflect.Constructor, java.util.ArrayList, .Comparator, .HashMap, .HashSet, .Iterator, .List, .Map, .Objects, .Set, org.hibernate.Internal, .MappingException, .Remove, org.hibernate.boot.model.relational.Database, .ExportableProducer, .SqlStringGenerationContext, org.hibernate.boot.model.source.internal.hbm.MappingDocument, org.hibernate.boot.registry.classloading.spi.ClassLoaderService, .ClassLoadingException, org.hibernate.boot.spi.BootstrapContext, .MetadataBuildingContext, org.hibernate.dialect.Dialect, org.hibernate.engine.spi.Mapping, .SharedSessionContractImplementor, org.hibernate.id.CompositeNestedGeneratedValueGenerator, .IdentifierGenerationException, .IdentifierGenerator, org.hibernate.id.factory.IdentifierGeneratorFactory, org.hibernate.internal.util.ReflectHelper, org.hibernate.internal.util.collections.ArrayHelper, .CollectionHelper, org.hibernate.metamodel.spi.EmbeddableInstantiator, org.hibernate.property.access.spi.Setter, org.hibernate.generator.Generator, .BeforeExecutionGenerator, org.hibernate.resource.beans.internal.FallbackBeanInstanceProducer, org.hibernate.resource.beans.spi.ManagedBeanRegistry, org.hibernate.type.ComponentType, .CompositeType, .EmbeddedComponentType, .UserComponentType, org.hibernate.usertype.CompositeUserType

A mapping model object that represents an embeddable class.

API Note

The name of this class is historical and unfortunate. An embeddable class holds a "component" of the state of an entity. It has absolutely nothing to do with modularity in software engineering.

Authors
Gavin King, Steve Ebersole

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
public static class

Field Summary

Modifier and TypeField and Description
private AggregateColumn
private transient Generator
private transient List<Column>
private transient List<Selectable>
private String
private Class<? extends EmbeddableInstantiator>
private boolean
private boolean
private Constructor<?>
private String[]
private Boolean
private boolean
private Map<String, MetaAttribute>
private int[]
private PersistentClass
private AggregateColumn
private String
private final ArrayList<Property>
private String
private String[]
private String
private volatile CompositeType
Inherited from org.hibernate.mapping.SimpleValue:
DEFAULT_ID_GEN_STRATEGY

Constructor Summary

AccessConstructor and Description
public
public
public
public
public
private
Component(Component original)

Method Summary

Modifier and TypeMethod and Description
public Object
public void
public void
private Generator
buildIdentifierGenerator(IdentifierGeneratorFactory identifierGeneratorFactory, Dialect dialect, RootClass rootClass)

public void
checkColumnDuplication(Set<String>
set containing the names of the columns to check
distinctColumns
,
String
the owner of this value, used just for error reporting
owner
)

Overrides default org.hibernate.mapping.Value.checkColumnDuplication.

Checks if this value contains any duplicate column.
private void
collectAggregatedColumns(List<Column> aggregatedColumns, Component component)

public Component
private CompositeUserType<?>
public Generator
public AggregateColumn
public List<Column>
public boolean[]
public List<Column>
getColumns()

Overrides org.hibernate.mapping.SimpleValue.getColumns.

Implements org.hibernate.mapping.Value.getColumns.

If the mapping involves only columns, return them.
public int
getColumnSpan()

Overrides org.hibernate.mapping.SimpleValue.getColumnSpan.

Implements org.hibernate.mapping.Value.getColumnSpan.

The number of columns and formulas in the mapping.
public boolean[]
public Class<?>
public String
public Class<? extends EmbeddableInstantiator>
public Constructor<?>
public String[]
public MetaAttribute
public Map<String, MetaAttribute>
public PersistentClass
public AggregateColumn
public String
public List<Property>
public Property

Returns:

Property
getProperty
(int
index of the Property to return
index
)

Returns the Property at the specified position in this Component.

public Property
getProperty(String propertyName)

public @Remove Iterator<Property>
getPropertyIterator()

Deprecated
public String[]
public int
public String
public List<Selectable>
public String[]
public String
public CompositeType
public boolean
public boolean
public boolean
public boolean
hasProperty(String propertyName)

private Setter
injector(Property property, Class<?> attributeDeclarer)

public boolean
public boolean
public boolean
public boolean
public boolean
public boolean
private boolean
public boolean
public boolean
isValid(Mapping mapping)

Overrides org.hibernate.mapping.SimpleValue.isValid.

Implements org.hibernate.mapping.Value.isValid.

Deprecated as a consequence of Mapping being deprecated.
public boolean
matchesAllProperties(String... propertyNames)

private void
public void
private void
private Class<?>
public void
public void
setComponentClassName(String componentClass)

public void
setCustomInstantiator(Class<? extends EmbeddableInstantiator> customInstantiator)

public void
setDynamic(boolean dynamic)

public void
setEmbedded(boolean embedded)

public void
setGeneric(boolean generic)

public void
setInstantiator(Constructor<?> instantiator, String[] instantiatorPropertyNames)

public void
setKey(boolean isKey)

public void
public void
public void
public void
setParentProperty(String parentProperty)

public void
setRoleName(String roleName)

public void
setStructColumnNames(String[] structColumnNames)

public void
setStructName(String structName)

public void
public int[]
private int[]
sortProperties(boolean forceRetainOriginalOrder)

public String
toString()

Overrides org.hibernate.mapping.SimpleValue.toString.

Returns a string representation of the object.
Inherited from org.hibernate.mapping.SimpleValue:
addColumnaddFormulacopyTypeFromcreateForeignKeycreateForeignKeycreateForeignKeyOfEntitycreateParameterImplcreateUniqueKeydisableForeignKeygetAttributeConverterDescriptorgetBuildingContextgetColumngetConstraintColumnIteratorgetCustomIdGeneratorCreatorgetFetchModegetForeignKeyDefinitiongetForeignKeyNamegetIdentifierGeneratorgetIdentifierGeneratorParametersgetIdentifierGeneratorPropertiesgetIdentifierGeneratorStrategygetJpaAttributeConverterDescriptorgetMetadatagetNullValuegetOnDeleteActiongetServiceRegistrygetTablegetTypeConfigurationgetTypeNamegetTypeParametershasFormulaisAlternateUniqueKeyisCascadeDeleteEnabledisColumnInsertableisColumnUpdateableisConstrainedisForeignKeyEnabledisIdentityColumnisLobisNationalizedisNullableisPartitionKeyisSameisSameisSimpleValueisTypeSpecifiedisUpdateableisVersionjustAddColumnjustAddColumnjustAddFormulamakeLobmakeNationalizedmakeParameterImplmakeVersionsetAlternateUniqueKeysetAttributeConverterDescriptorsetCascadeDeleteEnabledsetCustomIdGeneratorCreatorsetForeignKeyDefinitionsetForeignKeyNamesetIdentifierGeneratorParameterssetIdentifierGeneratorPropertiessetIdentifierGeneratorPropertiessetIdentifierGeneratorStrategysetJpaAttributeConverterDescriptorsetNullValuesetOnDeleteActionsetPartitionKeysetTablesetTypeNamesetTypeParameterssetTypeParameterssortColumns