public class OneToOne extends java.lang.Object implements RelationField
Java class for one-to-one complex type.
The following schema fragment specifies the expected content contained within this class.
<complexType name="one-to-one"> <complexContent> <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> <sequence> <choice> <element name="primary-key-join-column" type="{http://java.sun.com/xml/ns/persistence/orm}primary-key-join-column" maxOccurs="unbounded" minOccurs="0"/> <element name="join-column" type="{http://java.sun.com/xml/ns/persistence/orm}join-column" maxOccurs="unbounded" minOccurs="0"/> <element name="join-table" type="{http://java.sun.com/xml/ns/persistence/orm}join-table" minOccurs="0"/> </choice> <element name="cascade" type="{http://java.sun.com/xml/ns/persistence/orm}cascade-type" minOccurs="0"/> </sequence> <attribute name="fetch" type="{http://java.sun.com/xml/ns/persistence/orm}fetch-type" /> <attribute name="mapped-by" type="{http://www.w3.org/2001/XMLSchema}string" /> <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /> <attribute name="optional" type="{http://www.w3.org/2001/XMLSchema}boolean" /> <attribute name="target-entity" type="{http://www.w3.org/2001/XMLSchema}string" /> <attribute name="access" type="{http://java.sun.com/xml/ns/persistence/orm}access-type" /> <attribute name="orphan-removal" type="{http://www.w3.org/2001/XMLSchema}boolean" /> <attribute name="maps-id" type="{http://www.w3.org/2001/XMLSchema}string" /> <attribute name="id" type="{http://www.w3.org/2001/XMLSchema}boolean" /> </restriction> </complexContent> </complexType>
Modifier and Type | Field and Description |
---|---|
protected AccessType |
access |
protected CascadeType |
cascade |
protected FetchType |
fetch |
protected java.lang.Boolean |
id |
protected java.util.List<JoinColumn> |
joinColumn |
protected JoinTable |
joinTable |
protected java.lang.String |
mappedBy |
protected java.lang.String |
mapsId |
protected java.lang.String |
name |
protected java.lang.Boolean |
optional |
protected java.lang.Boolean |
orphanRemoval |
protected java.util.List<PrimaryKeyJoinColumn> |
primaryKeyJoinColumn |
protected RelationField |
relatedField |
protected boolean |
syntheticField |
protected java.lang.String |
targetEntity |
Constructor and Description |
---|
OneToOne() |
Modifier and Type | Method and Description |
---|---|
AccessType |
getAccess()
Gets the value of the access property.
|
CascadeType |
getCascade()
Gets the value of the cascade property.
|
FetchType |
getFetch()
Gets the value of the fetch property.
|
java.util.List<JoinColumn> |
getJoinColumn()
Gets the value of the joinColumn property.
|
JoinTable |
getJoinTable()
Gets the value of the joinTable property.
|
java.lang.Object |
getKey()
Gets the immutable key for this object.
|
java.lang.String |
getMappedBy()
Gets the value of the mappedBy property.
|
java.lang.String |
getMapsId()
Gets the value of the mapsId property.
|
java.lang.String |
getName()
Gets the value of the name property.
|
java.util.List<PrimaryKeyJoinColumn> |
getPrimaryKeyJoinColumn()
Gets the value of the primaryKeyJoinColumn property.
|
RelationField |
getRelatedField()
This is only used for xml converters and will normally return null.
|
java.lang.String |
getTargetEntity()
Gets the value of the targetEntity property.
|
java.lang.Boolean |
isId()
Gets the value of the id property.
|
java.lang.Boolean |
isOptional()
Gets the value of the optional property.
|
java.lang.Boolean |
isOrphanRemoval()
Gets the value of the orphanRemoval property.
|
boolean |
isSyntheticField()
This is only used for xml converters and will normally return false.
|
void |
setAccess(AccessType value)
Sets the value of the access property.
|
void |
setCascade(CascadeType value)
Sets the value of the cascade property.
|
void |
setFetch(FetchType value)
Sets the value of the fetch property.
|
void |
setId(java.lang.Boolean value)
Sets the value of the id property.
|
void |
setJoinTable(JoinTable value)
Sets the value of the joinTable property.
|
void |
setMappedBy(java.lang.String value)
Sets the value of the mappedBy property.
|
void |
setMapsId(java.lang.String value)
Sets the value of the mapsId property.
|
void |
setName(java.lang.String value)
Sets the value of the name property.
|
void |
setOptional(java.lang.Boolean value)
Sets the value of the optional property.
|
void |
setOrphanRemoval(java.lang.Boolean value)
Sets the value of the orphanRemoval property.
|
void |
setRelatedField(RelationField value)
Gets the field on the target entity for this relationship.
|
void |
setSyntheticField(boolean syntheticField)
This is only used for xml converters and will normally return false.
|
void |
setTargetEntity(java.lang.String value)
Sets the value of the targetEntity property.
|
protected java.util.List<PrimaryKeyJoinColumn> primaryKeyJoinColumn
protected java.util.List<JoinColumn> joinColumn
protected JoinTable joinTable
protected CascadeType cascade
protected FetchType fetch
protected AccessType access
protected java.lang.String mappedBy
protected java.lang.Boolean orphanRemoval
protected java.lang.String mapsId
protected java.lang.Boolean id
protected java.lang.String name
protected java.lang.Boolean optional
protected java.lang.String targetEntity
protected RelationField relatedField
protected boolean syntheticField
public java.util.List<PrimaryKeyJoinColumn> getPrimaryKeyJoinColumn()
set
method for the primaryKeyJoinColumn property.
For example, to add a new item, do as follows:
getPrimaryKeyJoinColumn().add(newItem);Objects of the following type(s) are allowed in the list
PrimaryKeyJoinColumn
public java.util.List<JoinColumn> getJoinColumn()
set
method for the joinColumn property.
For example, to add a new item, do as follows:
getJoinColumn().add(newItem);Objects of the following type(s) are allowed in the list
JoinColumn
getJoinColumn
in interface RelationField
public JoinTable getJoinTable()
getJoinTable
in interface RelationField
JoinTable
public void setJoinTable(JoinTable value)
setJoinTable
in interface RelationField
value
- allowed object is
JoinTable
public CascadeType getCascade()
getCascade
in interface RelationField
CascadeType
public void setCascade(CascadeType value)
setCascade
in interface RelationField
value
- allowed object is
CascadeType
public FetchType getFetch()
getFetch
in interface RelationField
FetchType
public void setFetch(FetchType value)
setFetch
in interface RelationField
value
- allowed object is
FetchType
public AccessType getAccess()
AccessType
public void setAccess(AccessType value)
value
- allowed object is
AccessType
public java.lang.String getMappedBy()
getMappedBy
in interface RelationField
String
public void setMappedBy(java.lang.String value)
setMappedBy
in interface RelationField
value
- allowed object is
String
public java.lang.Boolean isOrphanRemoval()
Boolean
public void setOrphanRemoval(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.String getMapsId()
String
public void setMapsId(java.lang.String value)
value
- allowed object is
String
public java.lang.Boolean isId()
Boolean
public void setId(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.String getName()
getName
in interface RelationField
String
public void setName(java.lang.String value)
setName
in interface RelationField
value
- allowed object is
String
public java.lang.Boolean isOptional()
Boolean
public void setOptional(java.lang.Boolean value)
value
- allowed object is
Boolean
public java.lang.String getTargetEntity()
getTargetEntity
in interface RelationField
String
public void setTargetEntity(java.lang.String value)
setTargetEntity
in interface RelationField
value
- allowed object is
String
public RelationField getRelatedField()
getRelatedField
in interface RelationField
public void setRelatedField(RelationField value)
setRelatedField
in interface RelationField
value
- field on the target entity for this relationship.public boolean isSyntheticField()
RelationField
isSyntheticField
in interface RelationField
public void setSyntheticField(boolean syntheticField)
RelationField
setSyntheticField
in interface RelationField