blob: 0db1fa5d8e2113e4ee32fb8ffa2fae02188acfcd [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_252) on Fri Jul 16 09:38:36 UTC 2021 -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>VariableOneToOne (EclipseLink 3.0.2, API Reference)</title>
<meta name="date" content="2021-07-16">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="VariableOneToOne (EclipseLink 3.0.2, API Reference)";
}
}
catch(err) {
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
<div class="aboutLanguage">EclipseLink 3.0.2, API Reference</div>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/eclipse/persistence/annotations/ValuePartitioning.html" title="annotation in org.eclipse.persistence.annotations"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../org/eclipse/persistence/annotations/VirtualAccessMethods.html" title="annotation in org.eclipse.persistence.annotations"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/eclipse/persistence/annotations/VariableOneToOne.html" target="_top">Frames</a></li>
<li><a href="VariableOneToOne.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Required&nbsp;|&nbsp;</li>
<li><a href="#annotation.type.optional.element.summary">Optional</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#annotation.type.element.detail">Element</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.eclipse.persistence.annotations</div>
<h2 title="Annotation Type VariableOneToOne" class="title">Annotation Type VariableOneToOne</h2>
</div>
<div class="contentContainer">
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/Target.html?is-external=true#value--" title="class or interface in java.lang.annotation">value</a>={<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/ElementType.html?is-external=true#METHOD" title="class or interface in java.lang.annotation">METHOD</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</a>})
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/Retention.html?is-external=true#value--" title="class or interface in java.lang.annotation">value</a>=<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</a>)
public @interface <span class="memberNameLabel">VariableOneToOne</span></pre>
<div class="block">Variable one to one mappings are used to represent a pointer references
between a java object and an implementer of an interface. This mapping is
usually represented by a single pointer (stored in an instance variable)
between the source and target objects. In the relational database tables,
these mappings are normally implemented using a foreign key and a type code.
A VariableOneToOne can be specified within an Entity, MappedSuperclass
and Embeddable class.</div>
<dl>
<dt><span class="simpleTagLabel">Author:</span></dt>
<dd>Guy Pelletier</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>Eclipselink 1.0</dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== ANNOTATION TYPE OPTIONAL MEMBER SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="annotation.type.optional.element.summary">
<!-- -->
</a>
<h3>Optional Element Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Optional Element Summary table, listing optional elements, and an explanation">
<caption><span>Optional Elements</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Optional Element and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>jakarta.persistence.CascadeType[]</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#cascade--">cascade</a></span></code>
<div class="block">(Optional) The operations that must be cascaded to the target of the
association.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code><a href="../../../../org/eclipse/persistence/annotations/DiscriminatorClass.html" title="annotation in org.eclipse.persistence.annotations">DiscriminatorClass</a>[]</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#discriminatorClasses--">discriminatorClasses</a></span></code>
<div class="block">(Optional) The list of discriminator types that can be used with this
VariableOneToOne.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>jakarta.persistence.DiscriminatorColumn</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#discriminatorColumn--">discriminatorColumn</a></span></code>
<div class="block">(Optional) The discriminator column will hold the type indicators.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>jakarta.persistence.FetchType</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#fetch--">fetch</a></span></code>
<div class="block">(Optional) Defines whether the value of the field or property should
be lazily loaded or must be eagerly fetched.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#optional--">optional</a></span></code>
<div class="block">(Optional) Whether the association is optional.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#orphanRemoval--">orphanRemoval</a></span></code>
<div class="block">(Optional) Whether to apply the remove operation to entities that have
been removed from the relationship and to cascade the remove operation to
those entities.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/eclipse/persistence/annotations/VariableOneToOne.html#targetInterface--">targetInterface</a></span></code>
<div class="block">(Optional) The interface class that is the target of the association.</div>
</td>
</tr>
</table>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="annotation.type.element.detail">
<!-- -->
</a>
<h3>Element Detail</h3>
<a name="targetInterface--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>targetInterface</h4>
<pre>public abstract&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&nbsp;targetInterface</pre>
<div class="block">(Optional) The interface class that is the target of the association. If
not specified it will be inferred from the type of the object being
referenced.</div>
<dl>
<dt>Default:</dt>
<dd>void.class</dd>
</dl>
</li>
</ul>
</li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="cascade--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cascade</h4>
<pre>public abstract&nbsp;jakarta.persistence.CascadeType[]&nbsp;cascade</pre>
<div class="block">(Optional) The operations that must be cascaded to the target of the
association.</div>
<dl>
<dt>Default:</dt>
<dd>{}</dd>
</dl>
</li>
</ul>
</li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="fetch--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>fetch</h4>
<pre>public abstract&nbsp;jakarta.persistence.FetchType&nbsp;fetch</pre>
<div class="block">(Optional) Defines whether the value of the field or property should
be lazily loaded or must be eagerly fetched. The EAGER strategy is a
requirement on the persistence provider runtime that the value must be
eagerly fetched. The LAZY strategy is a hint to the persistence provider
runtime. If not specified, defaults to EAGER.</div>
<dl>
<dt>Default:</dt>
<dd>jakarta.persistence.FetchType.EAGER</dd>
</dl>
</li>
</ul>
</li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="optional--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>optional</h4>
<pre>public abstract&nbsp;boolean&nbsp;optional</pre>
<div class="block">(Optional) Whether the association is optional. If set to false then a
non-null relationship must always exist.</div>
<dl>
<dt>Default:</dt>
<dd>true</dd>
</dl>
</li>
</ul>
</li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="orphanRemoval--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>orphanRemoval</h4>
<pre>public abstract&nbsp;boolean&nbsp;orphanRemoval</pre>
<div class="block">(Optional) Whether to apply the remove operation to entities that have
been removed from the relationship and to cascade the remove operation to
those entities.</div>
<dl>
<dt>Default:</dt>
<dd>false</dd>
</dl>
</li>
</ul>
</li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="discriminatorColumn--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>discriminatorColumn</h4>
<pre>public abstract&nbsp;jakarta.persistence.DiscriminatorColumn&nbsp;discriminatorColumn</pre>
<div class="block">(Optional) The discriminator column will hold the type indicators. If the
DiscriminatorColumn is not specified, the name of the discriminator
column defaults to "DTYPE" and the discriminator type to STRING.</div>
<dl>
<dt>Default:</dt>
<dd>@jakarta.persistence.DiscriminatorColumn</dd>
</dl>
</li>
</ul>
</li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="discriminatorClasses--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>discriminatorClasses</h4>
<pre>public abstract&nbsp;<a href="../../../../org/eclipse/persistence/annotations/DiscriminatorClass.html" title="annotation in org.eclipse.persistence.annotations">DiscriminatorClass</a>[]&nbsp;discriminatorClasses</pre>
<div class="block">(Optional) The list of discriminator types that can be used with this
VariableOneToOne. If none are specified then those entities within the
persistence unit that implement the target interface will be added to
the list of types. The discriminator type will default as follows:
- If DiscriminatorColumn type is STRING: Entity.name()
- If DiscriminatorColumn type is CHAR: First letter of the Entity class
- If DiscriminatorColumn type is INTEGER: The next integer after the
highest integer explicitly added.</div>
<dl>
<dt>Default:</dt>
<dd>{}</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
<div class="aboutLanguage">EclipseLink 3.0.2, API Reference</div>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/eclipse/persistence/annotations/ValuePartitioning.html" title="annotation in org.eclipse.persistence.annotations"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../org/eclipse/persistence/annotations/VirtualAccessMethods.html" title="annotation in org.eclipse.persistence.annotations"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/eclipse/persistence/annotations/VariableOneToOne.html" target="_top">Frames</a></li>
<li><a href="VariableOneToOne.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Required&nbsp;|&nbsp;</li>
<li><a href="#annotation.type.optional.element.summary">Optional</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#annotation.type.element.detail">Element</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &#169; 2007&#x2013;2021 <a href="http://www.eclipse.org/eclipselink">Eclipse.org - EclipseLink Project</a>. All rights reserved.</small></p>
</body>
</html>