public class ManyToMany extends Object
@Target({METHOD, FIELD}) @Retention(RUNTIME) public @interface ManyToMany { Class targetEntity() default void.class; CascadeType[] cascade() default {}; FetchType fetch() default LAZY; String mappedBy() default ""; }
<p>Java class for many-to-many complex type.
<p>The following schema fragment specifies the expected content contained within this class.
<pre> <complexType name="many-to-many"> <complexContent> <restriction base="{http://www.w3.org/2001/XMLSchema}anyType"> <sequence> <choice> <element name="order-by" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}order-by" minOccurs="0"/> <element name="order-column" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}order-column" minOccurs="0"/> </choice> <choice> <element name="map-key" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}map-key" minOccurs="0"/> <sequence> <element name="map-key-class" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}map-key-class" minOccurs="0"/> <choice> <element name="map-key-temporal" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}temporal" minOccurs="0"/> <element name="map-key-enumerated" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}enumerated" minOccurs="0"/> <sequence> <element name="map-key-attribute-override" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}attribute-override" maxOccurs="unbounded" minOccurs="0"/> <element name="map-key-convert" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}convert" maxOccurs="unbounded" minOccurs="0"/> </sequence> </choice> <choice> <element name="map-key-column" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}map-key-column" minOccurs="0"/> <sequence> <element name="map-key-join-column" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}map-key-join-column" maxOccurs="unbounded" minOccurs="0"/> <element name="map-key-foreign-key" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}foreign-key" minOccurs="0"/> </sequence> </choice> </sequence> </choice> <element name="join-table" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}join-table" minOccurs="0"/> <element name="cascade" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}cascade-type" minOccurs="0"/> </sequence> <attribute name="name" use="required" type="{http://www.w3.org/2001/XMLSchema}string" /> <attribute name="target-entity" type="{http://www.w3.org/2001/XMLSchema}string" /> <attribute name="fetch" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}fetch-type" /> <attribute name="access" type="{http://xmlns.jcp.org/xml/ns/persistence/orm}access-type" /> <attribute name="mapped-by" type="{http://www.w3.org/2001/XMLSchema}string" /> </restriction> </complexContent> </complexType> </pre>
| Modifier and Type | Field and Description |
|---|---|
protected AccessType |
access |
protected CascadeType |
cascade |
protected FetchType |
fetch |
protected JoinTable |
joinTable |
protected MapKey |
mapKey |
protected List<AttributeOverride> |
mapKeyAttributeOverride |
protected MapKeyClass |
mapKeyClass |
protected MapKeyColumn |
mapKeyColumn |
protected List<Convert> |
mapKeyConvert |
protected EnumType |
mapKeyEnumerated |
protected ForeignKey |
mapKeyForeignKey |
protected List<MapKeyJoinColumn> |
mapKeyJoinColumn |
protected TemporalType |
mapKeyTemporal |
protected String |
mappedBy |
protected String |
name |
protected String |
orderBy |
protected OrderColumn |
orderColumn |
protected String |
targetEntity |
| Constructor and Description |
|---|
ManyToMany() |
| 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.
|
JoinTable |
getJoinTable()
Gets the value of the joinTable property.
|
MapKey |
getMapKey()
Gets the value of the mapKey property.
|
List<AttributeOverride> |
getMapKeyAttributeOverride()
Gets the value of the mapKeyAttributeOverride property.
|
MapKeyClass |
getMapKeyClass()
Gets the value of the mapKeyClass property.
|
MapKeyColumn |
getMapKeyColumn()
Gets the value of the mapKeyColumn property.
|
List<Convert> |
getMapKeyConvert()
Gets the value of the mapKeyConvert property.
|
EnumType |
getMapKeyEnumerated()
Gets the value of the mapKeyEnumerated property.
|
ForeignKey |
getMapKeyForeignKey()
Gets the value of the mapKeyForeignKey property.
|
List<MapKeyJoinColumn> |
getMapKeyJoinColumn()
Gets the value of the mapKeyJoinColumn property.
|
TemporalType |
getMapKeyTemporal()
Gets the value of the mapKeyTemporal property.
|
String |
getMappedBy()
Gets the value of the mappedBy property.
|
String |
getName()
Gets the value of the name property.
|
String |
getOrderBy()
Gets the value of the orderBy property.
|
OrderColumn |
getOrderColumn()
Gets the value of the orderColumn property.
|
String |
getTargetEntity()
Gets the value of the targetEntity property.
|
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 |
setJoinTable(JoinTable value)
Sets the value of the joinTable property.
|
void |
setMapKey(MapKey value)
Sets the value of the mapKey property.
|
void |
setMapKeyClass(MapKeyClass value)
Sets the value of the mapKeyClass property.
|
void |
setMapKeyColumn(MapKeyColumn value)
Sets the value of the mapKeyColumn property.
|
void |
setMapKeyEnumerated(EnumType value)
Sets the value of the mapKeyEnumerated property.
|
void |
setMapKeyForeignKey(ForeignKey value)
Sets the value of the mapKeyForeignKey property.
|
void |
setMapKeyTemporal(TemporalType value)
Sets the value of the mapKeyTemporal property.
|
void |
setMappedBy(String value)
Sets the value of the mappedBy property.
|
void |
setName(String value)
Sets the value of the name property.
|
void |
setOrderBy(String value)
Sets the value of the orderBy property.
|
void |
setOrderColumn(OrderColumn value)
Sets the value of the orderColumn property.
|
void |
setTargetEntity(String value)
Sets the value of the targetEntity property.
|
protected String orderBy
protected OrderColumn orderColumn
protected MapKey mapKey
protected MapKeyClass mapKeyClass
protected TemporalType mapKeyTemporal
protected EnumType mapKeyEnumerated
protected List<AttributeOverride> mapKeyAttributeOverride
protected MapKeyColumn mapKeyColumn
protected List<MapKeyJoinColumn> mapKeyJoinColumn
protected ForeignKey mapKeyForeignKey
protected JoinTable joinTable
protected CascadeType cascade
protected String name
protected String targetEntity
protected FetchType fetch
protected AccessType access
protected String mappedBy
public String getOrderBy()
Gets the value of the orderBy property.
Stringpublic void setOrderBy(String value)
Sets the value of the orderBy property.
value - allowed object is
Stringpublic OrderColumn getOrderColumn()
Gets the value of the orderColumn property.
OrderColumnpublic void setOrderColumn(OrderColumn value)
Sets the value of the orderColumn property.
value - allowed object is
OrderColumnpublic MapKey getMapKey()
Gets the value of the mapKey property.
MapKeypublic void setMapKey(MapKey value)
Sets the value of the mapKey property.
value - allowed object is
MapKeypublic MapKeyClass getMapKeyClass()
Gets the value of the mapKeyClass property.
MapKeyClasspublic void setMapKeyClass(MapKeyClass value)
Sets the value of the mapKeyClass property.
value - allowed object is
MapKeyClasspublic TemporalType getMapKeyTemporal()
Gets the value of the mapKeyTemporal property.
TemporalTypepublic void setMapKeyTemporal(TemporalType value)
Sets the value of the mapKeyTemporal property.
value - allowed object is
TemporalTypepublic EnumType getMapKeyEnumerated()
Gets the value of the mapKeyEnumerated property.
EnumTypepublic void setMapKeyEnumerated(EnumType value)
Sets the value of the mapKeyEnumerated property.
value - allowed object is
EnumTypepublic List<AttributeOverride> getMapKeyAttributeOverride()
Gets the value of the mapKeyAttributeOverride property.
<p> 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 JAXB object. This is why there is not a <CODE>set</CODE> method for the mapKeyAttributeOverride property.
<p> For example, to add a new item, do as follows: <pre> getMapKeyAttributeOverride().add(newItem); </pre>
<p>
Objects of the following type(s) are allowed in the list
AttributeOverride
public List<Convert> getMapKeyConvert()
Gets the value of the mapKeyConvert property.
<p> 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 JAXB object. This is why there is not a <CODE>set</CODE> method for the mapKeyConvert property.
<p> For example, to add a new item, do as follows: <pre> getMapKeyConvert().add(newItem); </pre>
<p>
Objects of the following type(s) are allowed in the list
Convert
public MapKeyColumn getMapKeyColumn()
Gets the value of the mapKeyColumn property.
MapKeyColumnpublic void setMapKeyColumn(MapKeyColumn value)
Sets the value of the mapKeyColumn property.
value - allowed object is
MapKeyColumnpublic List<MapKeyJoinColumn> getMapKeyJoinColumn()
Gets the value of the mapKeyJoinColumn property.
<p> 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 JAXB object. This is why there is not a <CODE>set</CODE> method for the mapKeyJoinColumn property.
<p> For example, to add a new item, do as follows: <pre> getMapKeyJoinColumn().add(newItem); </pre>
<p>
Objects of the following type(s) are allowed in the list
MapKeyJoinColumn
public ForeignKey getMapKeyForeignKey()
Gets the value of the mapKeyForeignKey property.
ForeignKeypublic void setMapKeyForeignKey(ForeignKey value)
Sets the value of the mapKeyForeignKey property.
value - allowed object is
ForeignKeypublic JoinTable getJoinTable()
Gets the value of the joinTable property.
JoinTablepublic void setJoinTable(JoinTable value)
Sets the value of the joinTable property.
value - allowed object is
JoinTablepublic CascadeType getCascade()
Gets the value of the cascade property.
CascadeTypepublic void setCascade(CascadeType value)
Sets the value of the cascade property.
value - allowed object is
CascadeTypepublic String getName()
Gets the value of the name property.
Stringpublic void setName(String value)
Sets the value of the name property.
value - allowed object is
Stringpublic String getTargetEntity()
Gets the value of the targetEntity property.
Stringpublic void setTargetEntity(String value)
Sets the value of the targetEntity property.
value - allowed object is
Stringpublic FetchType getFetch()
Gets the value of the fetch property.
FetchTypepublic void setFetch(FetchType value)
Sets the value of the fetch property.
value - allowed object is
FetchTypepublic AccessType getAccess()
Gets the value of the access property.
AccessTypepublic void setAccess(AccessType value)
Sets the value of the access property.
value - allowed object is
AccessTypepublic String getMappedBy()
Gets the value of the mappedBy property.
StringCopyright © 2001-2018 Red Hat, Inc. All Rights Reserved.