1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> 2<!-- NewPage --> 3<html lang="en"> 4<head> 5<!-- Generated by javadoc (version 1.7.0_79) on Sat Jan 09 21:46:11 PST 2016 --> 6<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 7<title>JsonManagedReference (Jackson-annotations 2.7.0 API)</title> 8<meta name="date" content="2016-01-09"> 9<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style"> 10</head> 11<body> 12<script type="text/javascript"><!-- 13 if (location.href.indexOf('is-external=true') == -1) { 14 parent.document.title="JsonManagedReference (Jackson-annotations 2.7.0 API)"; 15 } 16//--> 17</script> 18<noscript> 19<div>JavaScript is disabled on your browser.</div> 20</noscript> 21<!-- ========= START OF TOP NAVBAR ======= --> 22<div class="topNav"><a name="navbar_top"> 23<!-- --> 24</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> 25<!-- --> 26</a> 27<ul class="navList" title="Navigation"> 28<li><a href="../../../../com/fasterxml/jackson/annotation/package-summary.html">Package</a></li> 29<li class="navBarCell1Rev">Class</li> 30<li><a href="class-use/JsonManagedReference.html">Use</a></li> 31<li><a href="package-tree.html">Tree</a></li> 32<li><a href="../../../../deprecated-list.html">Deprecated</a></li> 33<li><a href="../../../../index-all.html">Index</a></li> 34<li><a href="../../../../help-doc.html">Help</a></li> 35</ul> 36</div> 37<div class="subNav"> 38<ul class="navList"> 39<li><a href="../../../../com/fasterxml/jackson/annotation/JsonInclude.Value.html" title="class in com.fasterxml.jackson.annotation"><span class="strong">Prev Class</span></a></li> 40<li><a href="../../../../com/fasterxml/jackson/annotation/JsonProperty.html" title="annotation in com.fasterxml.jackson.annotation"><span class="strong">Next Class</span></a></li> 41</ul> 42<ul class="navList"> 43<li><a href="../../../../index.html?com/fasterxml/jackson/annotation/JsonManagedReference.html" target="_top">Frames</a></li> 44<li><a href="JsonManagedReference.html" target="_top">No Frames</a></li> 45</ul> 46<ul class="navList" id="allclasses_navbar_top"> 47<li><a href="../../../../allclasses-noframe.html">All Classes</a></li> 48</ul> 49<div> 50<script type="text/javascript"><!-- 51 allClassesLink = document.getElementById("allclasses_navbar_top"); 52 if(window==top) { 53 allClassesLink.style.display = "block"; 54 } 55 else { 56 allClassesLink.style.display = "none"; 57 } 58 //--> 59</script> 60</div> 61<div> 62<ul class="subNavList"> 63<li>Summary: </li> 64<li>Required | </li> 65<li><a href="#annotation_type_optional_element_summary">Optional</a></li> 66</ul> 67<ul class="subNavList"> 68<li>Detail: </li> 69<li><a href="#annotation_type_element_detail">Element</a></li> 70</ul> 71</div> 72<a name="skip-navbar_top"> 73<!-- --> 74</a></div> 75<!-- ========= END OF TOP NAVBAR ========= --> 76<!-- ======== START OF CLASS DATA ======== --> 77<div class="header"> 78<div class="subTitle">com.fasterxml.jackson.annotation</div> 79<h2 title="Annotation Type JsonManagedReference" class="title">Annotation Type JsonManagedReference</h2> 80</div> 81<div class="contentContainer"> 82<div class="description"> 83<ul class="blockList"> 84<li class="blockList"> 85<hr> 86<br> 87<pre><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</a>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/Target.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</a>={<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/ElementType.html?is-external=true#ANNOTATION_TYPE" title="class or interface in java.lang.annotation">ANNOTATION_TYPE</a>,<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</a>,<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/ElementType.html?is-external=true#METHOD" title="class or interface in java.lang.annotation">METHOD</a>}) 88<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</a>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/Retention.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</a>=<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</a>) 89public @interface <span class="strong">JsonManagedReference</span></pre> 90<div class="block">Annotation used to indicate that annotated property is part of 91 two-way linkage between fields; and that its role is "parent" (or "forward") link. 92 Value type (class) of property must have a single compatible property annotated with 93 <a href="../../../../com/fasterxml/jackson/annotation/JsonBackReference.html" title="annotation in com.fasterxml.jackson.annotation"><code>JsonBackReference</code></a>. Linkage is handled such that the property 94 annotated with this annotation is handled normally (serialized normally, no 95 special handling for deserialization); it is the matching back reference 96 that requires special handling 97<p> 98 All references have logical name to allow handling multiple linkages; typical case 99 would be that where nodes have both parent/child and sibling linkages. If so, 100 pairs of references should be named differently. 101 It is an error for a class too have multiple managed references with same name, 102 even if types pointed are different. 103<p> 104 Note: only methods and fields can be annotated with this annotation: constructor 105 arguments should NOT be annotated, as they can not be either managed or back 106 references.</div> 107<dl><dt><span class="strong">Author:</span></dt> 108 <dd>tatu</dd></dl> 109</li> 110</ul> 111</div> 112<div class="summary"> 113<ul class="blockList"> 114<li class="blockList"> 115<!-- =========== ANNOTATION TYPE OPTIONAL MEMBER SUMMARY =========== --> 116<ul class="blockList"> 117<li class="blockList"><a name="annotation_type_optional_element_summary"> 118<!-- --> 119</a> 120<h3>Optional Element Summary</h3> 121<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Optional Element Summary table, listing optional elements, and an explanation"> 122<caption><span>Optional Elements</span><span class="tabEnd"> </span></caption> 123<tr> 124<th class="colFirst" scope="col">Modifier and Type</th> 125<th class="colLast" scope="col">Optional Element and Description</th> 126</tr> 127<tr class="altColor"> 128<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td> 129<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/annotation/JsonManagedReference.html#value()">value</a></strong></code> 130<div class="block">Logical have for the reference property pair; used to link managed and 131 back references.</div> 132</td> 133</tr> 134</table> 135</li> 136</ul> 137</li> 138</ul> 139</div> 140<div class="details"> 141<ul class="blockList"> 142<li class="blockList"> 143<!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== --> 144<ul class="blockList"> 145<li class="blockList"><a name="annotation_type_element_detail"> 146<!-- --> 147</a> 148<h3>Element Detail</h3> 149<a name="value()"> 150<!-- --> 151</a> 152<ul class="blockListLast"> 153<li class="blockList"> 154<h4>value</h4> 155<pre>public abstract <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> value</pre> 156<div class="block">Logical have for the reference property pair; used to link managed and 157 back references. Default name can be used if there is just single 158 reference pair (for example, node class that just has parent/child linkage, 159 consisting of one managed reference and matching back reference)</div> 160<dl> 161<dt>Default:</dt> 162<dd>"defaultReference"</dd> 163</dl> 164</li> 165</ul> 166</li> 167</ul> 168</li> 169</ul> 170</div> 171</div> 172<!-- ========= END OF CLASS DATA ========= --> 173<!-- ======= START OF BOTTOM NAVBAR ====== --> 174<div class="bottomNav"><a name="navbar_bottom"> 175<!-- --> 176</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> 177<!-- --> 178</a> 179<ul class="navList" title="Navigation"> 180<li><a href="../../../../com/fasterxml/jackson/annotation/package-summary.html">Package</a></li> 181<li class="navBarCell1Rev">Class</li> 182<li><a href="class-use/JsonManagedReference.html">Use</a></li> 183<li><a href="package-tree.html">Tree</a></li> 184<li><a href="../../../../deprecated-list.html">Deprecated</a></li> 185<li><a href="../../../../index-all.html">Index</a></li> 186<li><a href="../../../../help-doc.html">Help</a></li> 187</ul> 188</div> 189<div class="subNav"> 190<ul class="navList"> 191<li><a href="../../../../com/fasterxml/jackson/annotation/JsonInclude.Value.html" title="class in com.fasterxml.jackson.annotation"><span class="strong">Prev Class</span></a></li> 192<li><a href="../../../../com/fasterxml/jackson/annotation/JsonProperty.html" title="annotation in com.fasterxml.jackson.annotation"><span class="strong">Next Class</span></a></li> 193</ul> 194<ul class="navList"> 195<li><a href="../../../../index.html?com/fasterxml/jackson/annotation/JsonManagedReference.html" target="_top">Frames</a></li> 196<li><a href="JsonManagedReference.html" target="_top">No Frames</a></li> 197</ul> 198<ul class="navList" id="allclasses_navbar_bottom"> 199<li><a href="../../../../allclasses-noframe.html">All Classes</a></li> 200</ul> 201<div> 202<script type="text/javascript"><!-- 203 allClassesLink = document.getElementById("allclasses_navbar_bottom"); 204 if(window==top) { 205 allClassesLink.style.display = "block"; 206 } 207 else { 208 allClassesLink.style.display = "none"; 209 } 210 //--> 211</script> 212</div> 213<div> 214<ul class="subNavList"> 215<li>Summary: </li> 216<li>Required | </li> 217<li><a href="#annotation_type_optional_element_summary">Optional</a></li> 218</ul> 219<ul class="subNavList"> 220<li>Detail: </li> 221<li><a href="#annotation_type_element_detail">Element</a></li> 222</ul> 223</div> 224<a name="skip-navbar_bottom"> 225<!-- --> 226</a></div> 227<!-- ======== END OF BOTTOM NAVBAR ======= --> 228<p class="legalCopy"><small>Copyright © 2008–2016 <a href="http://fasterxml.com/">FasterXML</a>. All rights reserved.</small></p> 229</body> 230</html> 231