Class EntityMappings
- java.lang.Object
- org.hibernate.processor.xml.jaxb.EntityMappings
public classEntityMappingsextendsObject
The entity-mappings element is the root element of a mapping file. It contains the following four types of elements: 1. The persistence-unit-metadata element contains metadata for the entire persistence unit. It is undefined if this element occurs in multiple mapping files within the same persistence unit. 2. The package, schema, catalog and access elements apply to all of the entity, mapped-superclass and embeddable elements defined in the same file in which they occur. 3. The sequence-generator, table-generator, converter, named-query, named-native-query, named-stored-procedure-query, and sql-result-set-mapping elements are global to the persistence unit. It is undefined to have more than one sequence-generator or table-generator of the same name in the same or different mapping files in a persistence unit. It is undefined to have more than one named-query, named-native-query, sql-result-set-mapping, or named-stored-procedure-query of the same name in the same or different mapping files in a persistence unit. It is also undefined to have more than one converter for the same target type in the same or different mapping files in a persistence unit. 4. The entity, mapped-superclass and embeddable elements each define the mapping information for a managed persistent class. The mapping information contained in these elements may be complete or it may be partial.Java class for anonymous complex type.
The following schema fragment specifies the expected content contained within this class.
<complexType> <complexContent> <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> <sequence> <element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> <element name="persistence-unit-metadata" type="{https://jakarta.ee/xml/ns/persistence/orm}persistence-unit-metadata" minOccurs="0"/> <element name="package" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> <element name="schema" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> <element name="catalog" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/> <element name="access" type="{https://jakarta.ee/xml/ns/persistence/orm}access-type" minOccurs="0"/> <element name="sequence-generator" type="{https://jakarta.ee/xml/ns/persistence/orm}sequence-generator" maxOccurs="unbounded" minOccurs="0"/> <element name="table-generator" type="{https://jakarta.ee/xml/ns/persistence/orm}table-generator" maxOccurs="unbounded" minOccurs="0"/> <element name="named-query" type="{https://jakarta.ee/xml/ns/persistence/orm}named-query" maxOccurs="unbounded" minOccurs="0"/> <element name="named-native-query" type="{https://jakarta.ee/xml/ns/persistence/orm}named-native-query" maxOccurs="unbounded" minOccurs="0"/> <element name="named-stored-procedure-query" type="{https://jakarta.ee/xml/ns/persistence/orm}named-stored-procedure-query" maxOccurs="unbounded" minOccurs="0"/> <element name="sql-result-set-mapping" type="{https://jakarta.ee/xml/ns/persistence/orm}sql-result-set-mapping" maxOccurs="unbounded" minOccurs="0"/> <element name="mapped-superclass" type="{https://jakarta.ee/xml/ns/persistence/orm}mapped-superclass" maxOccurs="unbounded" minOccurs="0"/> <element name="entity" type="{https://jakarta.ee/xml/ns/persistence/orm}entity" maxOccurs="unbounded" minOccurs="0"/> <element name="embeddable" type="{https://jakarta.ee/xml/ns/persistence/orm}embeddable" maxOccurs="unbounded" minOccurs="0"/> <element name="converter" type="{https://jakarta.ee/xml/ns/persistence/orm}converter" maxOccurs="unbounded" minOccurs="0"/> </sequence> <attribute name="version" use="required" type="{https://jakarta.ee/xml/ns/persistence/orm}versionType" fixed="3.1" /> </restriction> </complexContent> </complexType>
Field Summary
Fields Modifier and Type Field Description protectedString_packageprotectedAccessTypeaccessprotectedStringcatalogprotectedList<Converter>converterprotectedStringdescriptionprotectedList<Embeddable>embeddableprotectedList<Entity>entityprotectedList<MappedSuperclass>mappedSuperclassprotectedList<NamedNativeQuery>namedNativeQueryprotectedList<NamedQuery>namedQueryprotectedList<NamedStoredProcedureQuery>namedStoredProcedureQueryprotectedPersistenceUnitMetadatapersistenceUnitMetadataprotectedStringschemaprotectedList<SequenceGenerator>sequenceGeneratorprotectedList<SqlResultSetMapping>sqlResultSetMappingprotectedList<TableGenerator>tableGeneratorprotectedStringversion
Constructor Summary
Constructors Constructor Description EntityMappings()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description AccessTypegetAccess()Gets the value of the access property.StringgetCatalog()Gets the value of the catalog property.List<Converter>getConverter()Gets the value of the converter property.StringgetDescription()Gets the value of the description property.List<Embeddable>getEmbeddable()Gets the value of the embeddable property.List<Entity>getEntity()Gets the value of the entity property.List<MappedSuperclass>getMappedSuperclass()Gets the value of the mappedSuperclass property.List<NamedNativeQuery>getNamedNativeQuery()Gets the value of the namedNativeQuery property.List<NamedQuery>getNamedQuery()Gets the value of the namedQuery property.List<NamedStoredProcedureQuery>getNamedStoredProcedureQuery()Gets the value of the namedStoredProcedureQuery property.StringgetPackage()Gets the value of the package property.PersistenceUnitMetadatagetPersistenceUnitMetadata()Gets the value of the persistenceUnitMetadata property.StringgetSchema()Gets the value of the schema property.List<SequenceGenerator>getSequenceGenerator()Gets the value of the sequenceGenerator property.List<SqlResultSetMapping>getSqlResultSetMapping()Gets the value of the sqlResultSetMapping property.List<TableGenerator>getTableGenerator()Gets the value of the tableGenerator property.StringgetVersion()Gets the value of the version property.voidsetAccess(AccessType value)Sets the value of the access property.voidsetCatalog(String value)Sets the value of the catalog property.voidsetDescription(String value)Sets the value of the description property.voidsetPackage(String value)Sets the value of the package property.voidsetPersistenceUnitMetadata(PersistenceUnitMetadata value)Sets the value of the persistenceUnitMetadata property.voidsetSchema(String value)Sets the value of the schema property.voidsetVersion(String value)Sets the value of the version property.
Field Detail
description
protected String description
persistenceUnitMetadata
protected PersistenceUnitMetadata persistenceUnitMetadata
_package
protected String _package
schema
protected String schema
catalog
protected String catalog
access
protected AccessType access
sequenceGenerator
protected List<SequenceGenerator> sequenceGenerator
tableGenerator
protected List<TableGenerator> tableGenerator
namedQuery
protected List<NamedQuery> namedQuery
namedNativeQuery
protected List<NamedNativeQuery> namedNativeQuery
namedStoredProcedureQuery
protected List<NamedStoredProcedureQuery> namedStoredProcedureQuery
sqlResultSetMapping
protected List<SqlResultSetMapping> sqlResultSetMapping
mappedSuperclass
protected List<MappedSuperclass> mappedSuperclass
embeddable
protected List<Embeddable> embeddable
version
protected String version
Method Detail
getDescription
public String getDescription()
Gets the value of the description property.- Returns:
- possible object is
String
setDescription
public void setDescription(String value)
Sets the value of the description property.- Parameters:
value- allowed object isString
getPersistenceUnitMetadata
public PersistenceUnitMetadata getPersistenceUnitMetadata()
Gets the value of the persistenceUnitMetadata property.- Returns:
- possible object is
PersistenceUnitMetadata
setPersistenceUnitMetadata
public void setPersistenceUnitMetadata(PersistenceUnitMetadata value)
Sets the value of the persistenceUnitMetadata property.- Parameters:
value- allowed object isPersistenceUnitMetadata
getPackage
public String getPackage()
Gets the value of the package property.- Returns:
- possible object is
String
setPackage
public void setPackage(String value)
Sets the value of the package property.- Parameters:
value- allowed object isString
getSchema
public String getSchema()
Gets the value of the schema property.- Returns:
- possible object is
String
setSchema
public void setSchema(String value)
Sets the value of the schema property.- Parameters:
value- allowed object isString
getCatalog
public String getCatalog()
Gets the value of the catalog property.- Returns:
- possible object is
String
setCatalog
public void setCatalog(String value)
Sets the value of the catalog property.- Parameters:
value- allowed object isString
getAccess
public AccessType getAccess()
Gets the value of the access property.- Returns:
- possible object is
AccessType
setAccess
public void setAccess(AccessType value)
Sets the value of the access property.- Parameters:
value- allowed object isAccessType
getSequenceGenerator
public List<SequenceGenerator> getSequenceGenerator()
Gets the value of the sequenceGenerator property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the sequenceGenerator property.For example, to add a new item, do as follows:
getSequenceGenerator().add(newItem);
Objects of the following type(s) are allowed in the list
SequenceGenerator- Returns:
- The value of the sequenceGenerator property.
getTableGenerator
public List<TableGenerator> getTableGenerator()
Gets the value of the tableGenerator property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the tableGenerator property.For example, to add a new item, do as follows:
getTableGenerator().add(newItem);
Objects of the following type(s) are allowed in the list
TableGenerator- Returns:
- The value of the tableGenerator property.
getNamedQuery
public List<NamedQuery> getNamedQuery()
Gets the value of the namedQuery property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the namedQuery property.For example, to add a new item, do as follows:
getNamedQuery().add(newItem);
Objects of the following type(s) are allowed in the list
NamedQuery- Returns:
- The value of the namedQuery property.
getNamedNativeQuery
public List<NamedNativeQuery> getNamedNativeQuery()
Gets the value of the namedNativeQuery property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the namedNativeQuery property.For example, to add a new item, do as follows:
getNamedNativeQuery().add(newItem);
Objects of the following type(s) are allowed in the list
NamedNativeQuery- Returns:
- The value of the namedNativeQuery property.
getNamedStoredProcedureQuery
public List<NamedStoredProcedureQuery> getNamedStoredProcedureQuery()
Gets the value of the namedStoredProcedureQuery property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the namedStoredProcedureQuery property.For example, to add a new item, do as follows:
getNamedStoredProcedureQuery().add(newItem);
Objects of the following type(s) are allowed in the list
NamedStoredProcedureQuery- Returns:
- The value of the namedStoredProcedureQuery property.
getSqlResultSetMapping
public List<SqlResultSetMapping> getSqlResultSetMapping()
Gets the value of the sqlResultSetMapping property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the sqlResultSetMapping property.For example, to add a new item, do as follows:
getSqlResultSetMapping().add(newItem);
Objects of the following type(s) are allowed in the list
SqlResultSetMapping- Returns:
- The value of the sqlResultSetMapping property.
getMappedSuperclass
public List<MappedSuperclass> getMappedSuperclass()
Gets the value of the mappedSuperclass property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the mappedSuperclass property.For example, to add a new item, do as follows:
getMappedSuperclass().add(newItem);
Objects of the following type(s) are allowed in the list
MappedSuperclass- Returns:
- The value of the mappedSuperclass property.
getEntity
public List<Entity> getEntity()
Gets the value of the entity property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the entity property.For example, to add a new item, do as follows:
getEntity().add(newItem);
Objects of the following type(s) are allowed in the list
Entity- Returns:
- The value of the entity property.
getEmbeddable
public List<Embeddable> getEmbeddable()
Gets the value of the embeddable property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the embeddable property.For example, to add a new item, do as follows:
getEmbeddable().add(newItem);
Objects of the following type(s) are allowed in the list
Embeddable- Returns:
- The value of the embeddable property.
getConverter
public List<Converter> getConverter()
Gets the value of the converter property.This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the Jakarta XML Binding object. This is why there is not a
setmethod for the converter property.For example, to add a new item, do as follows:
getConverter().add(newItem);
Objects of the following type(s) are allowed in the list
Converter- Returns:
- The value of the converter property.
getVersion
public String getVersion()
Gets the value of the version property.- Returns:
- possible object is
String