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 Tue Jan 23 20:10:06 PST 2018 --> 6<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 7<title>ObjectIdResolver (Jackson-annotations 2.9.0 API)</title> 8<meta name="date" content="2018-01-23"> 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="ObjectIdResolver (Jackson-annotations 2.9.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/ObjectIdResolver.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/ObjectIdGenerators.UUIDGenerator.html" title="class in com.fasterxml.jackson.annotation"><span class="strong">Prev Class</span></a></li> 40<li><a href="../../../../com/fasterxml/jackson/annotation/OptBoolean.html" title="enum 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/ObjectIdResolver.html" target="_top">Frames</a></li> 44<li><a href="ObjectIdResolver.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>Nested | </li> 65<li>Field | </li> 66<li>Constr | </li> 67<li><a href="#method_summary">Method</a></li> 68</ul> 69<ul class="subNavList"> 70<li>Detail: </li> 71<li>Field | </li> 72<li>Constr | </li> 73<li><a href="#method_detail">Method</a></li> 74</ul> 75</div> 76<a name="skip-navbar_top"> 77<!-- --> 78</a></div> 79<!-- ========= END OF TOP NAVBAR ========= --> 80<!-- ======== START OF CLASS DATA ======== --> 81<div class="header"> 82<div class="subTitle">com.fasterxml.jackson.annotation</div> 83<h2 title="Interface ObjectIdResolver" class="title">Interface ObjectIdResolver</h2> 84</div> 85<div class="contentContainer"> 86<div class="description"> 87<ul class="blockList"> 88<li class="blockList"> 89<dl> 90<dt>All Known Implementing Classes:</dt> 91<dd><a href="../../../../com/fasterxml/jackson/annotation/SimpleObjectIdResolver.html" title="class in com.fasterxml.jackson.annotation">SimpleObjectIdResolver</a></dd> 92</dl> 93<hr> 94<br> 95<pre>public interface <span class="strong">ObjectIdResolver</span></pre> 96<div class="block">Definition of API used for resolving actual Java object from 97 Object Identifiers (as annotated using <a href="../../../../com/fasterxml/jackson/annotation/JsonIdentityInfo.html" title="annotation in com.fasterxml.jackson.annotation"><code>JsonIdentityInfo</code></a>).</div> 98<dl><dt><span class="strong">Since:</span></dt> 99 <dd>2.4</dd></dl> 100</li> 101</ul> 102</div> 103<div class="summary"> 104<ul class="blockList"> 105<li class="blockList"> 106<!-- ========== METHOD SUMMARY =========== --> 107<ul class="blockList"> 108<li class="blockList"><a name="method_summary"> 109<!-- --> 110</a> 111<h3>Method Summary</h3> 112<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> 113<caption><span>Methods</span><span class="tabEnd"> </span></caption> 114<tr> 115<th class="colFirst" scope="col">Modifier and Type</th> 116<th class="colLast" scope="col">Method and Description</th> 117</tr> 118<tr class="altColor"> 119<td class="colFirst"><code>void</code></td> 120<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html#bindItem(com.fasterxml.jackson.annotation.ObjectIdGenerator.IdKey,%20java.lang.Object)">bindItem</a></strong>(<a href="../../../../com/fasterxml/jackson/annotation/ObjectIdGenerator.IdKey.html" title="class in com.fasterxml.jackson.annotation">ObjectIdGenerator.IdKey</a> id, 121 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo)</code> 122<div class="block">Method called when a POJO is deserialized and has an Object Identifier.</div> 123</td> 124</tr> 125<tr class="rowColor"> 126<td class="colFirst"><code>boolean</code></td> 127<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html#canUseFor(com.fasterxml.jackson.annotation.ObjectIdResolver)">canUseFor</a></strong>(<a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html" title="interface in com.fasterxml.jackson.annotation">ObjectIdResolver</a> resolverType)</code> 128<div class="block">Method called to check whether this resolver instance can be used for 129 Object Ids of specific resolver type; determination is based by passing a 130 configured "blueprint" (prototype) instance; from which the actual 131 instances are created (using <a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html#newForDeserialization(java.lang.Object)"><code>newForDeserialization(java.lang.Object)</code></a>).</div> 132</td> 133</tr> 134<tr class="altColor"> 135<td class="colFirst"><code><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html" title="interface in com.fasterxml.jackson.annotation">ObjectIdResolver</a></code></td> 136<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html#newForDeserialization(java.lang.Object)">newForDeserialization</a></strong>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> context)</code> 137<div class="block">Factory method called to create a new instance to use for 138 deserialization: needed since resolvers may have state (a pool of 139 objects).</div> 140</td> 141</tr> 142<tr class="rowColor"> 143<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></td> 144<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html#resolveId(com.fasterxml.jackson.annotation.ObjectIdGenerator.IdKey)">resolveId</a></strong>(<a href="../../../../com/fasterxml/jackson/annotation/ObjectIdGenerator.IdKey.html" title="class in com.fasterxml.jackson.annotation">ObjectIdGenerator.IdKey</a> id)</code> 145<div class="block">Method called when deserialization encounters the given Object Identifier 146 and requires the POJO associated with it.</div> 147</td> 148</tr> 149</table> 150</li> 151</ul> 152</li> 153</ul> 154</div> 155<div class="details"> 156<ul class="blockList"> 157<li class="blockList"> 158<!-- ============ METHOD DETAIL ========== --> 159<ul class="blockList"> 160<li class="blockList"><a name="method_detail"> 161<!-- --> 162</a> 163<h3>Method Detail</h3> 164<a name="bindItem(com.fasterxml.jackson.annotation.ObjectIdGenerator.IdKey, java.lang.Object)"> 165<!-- --> 166</a> 167<ul class="blockList"> 168<li class="blockList"> 169<h4>bindItem</h4> 170<pre>void bindItem(<a href="../../../../com/fasterxml/jackson/annotation/ObjectIdGenerator.IdKey.html" title="class in com.fasterxml.jackson.annotation">ObjectIdGenerator.IdKey</a> id, 171 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> pojo)</pre> 172<div class="block">Method called when a POJO is deserialized and has an Object Identifier. 173 Method exists so that implementation can keep track of existing object in 174 JSON stream that could be useful for further resolution.</div> 175<dl><dt><span class="strong">Parameters:</span></dt><dd><code>id</code> - The Object Identifer</dd><dd><code>pojo</code> - The POJO associated to that Identifier</dd></dl> 176</li> 177</ul> 178<a name="resolveId(com.fasterxml.jackson.annotation.ObjectIdGenerator.IdKey)"> 179<!-- --> 180</a> 181<ul class="blockList"> 182<li class="blockList"> 183<h4>resolveId</h4> 184<pre><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> resolveId(<a href="../../../../com/fasterxml/jackson/annotation/ObjectIdGenerator.IdKey.html" title="class in com.fasterxml.jackson.annotation">ObjectIdGenerator.IdKey</a> id)</pre> 185<div class="block">Method called when deserialization encounters the given Object Identifier 186 and requires the POJO associated with it.</div> 187<dl><dt><span class="strong">Parameters:</span></dt><dd><code>id</code> - The Object Identifier</dd> 188<dt><span class="strong">Returns:</span></dt><dd>The POJO, or null if unable to resolve.</dd></dl> 189</li> 190</ul> 191<a name="newForDeserialization(java.lang.Object)"> 192<!-- --> 193</a> 194<ul class="blockList"> 195<li class="blockList"> 196<h4>newForDeserialization</h4> 197<pre><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html" title="interface in com.fasterxml.jackson.annotation">ObjectIdResolver</a> newForDeserialization(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a> context)</pre> 198<div class="block">Factory method called to create a new instance to use for 199 deserialization: needed since resolvers may have state (a pool of 200 objects). 201 <p> 202 Note that actual type of 'context' is 203 <code>com.fasterxml.jackson.databind.DeserializationContext</code>, but 204 can not be declared here as type itself (as well as call to this object) 205 comes from databind package.</div> 206<dl><dt><span class="strong">Parameters:</span></dt><dd><code>context</code> - Deserialization context object used (of type 207 <code>com.fasterxml.jackson.databind.DeserializationContext</code> 208 ; may be needed by more complex resolvers to access contextual 209 information such as configuration.</dd></dl> 210</li> 211</ul> 212<a name="canUseFor(com.fasterxml.jackson.annotation.ObjectIdResolver)"> 213<!-- --> 214</a> 215<ul class="blockListLast"> 216<li class="blockList"> 217<h4>canUseFor</h4> 218<pre>boolean canUseFor(<a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html" title="interface in com.fasterxml.jackson.annotation">ObjectIdResolver</a> resolverType)</pre> 219<div class="block">Method called to check whether this resolver instance can be used for 220 Object Ids of specific resolver type; determination is based by passing a 221 configured "blueprint" (prototype) instance; from which the actual 222 instances are created (using <a href="../../../../com/fasterxml/jackson/annotation/ObjectIdResolver.html#newForDeserialization(java.lang.Object)"><code>newForDeserialization(java.lang.Object)</code></a>).</div> 223<dl><dt><span class="strong">Returns:</span></dt><dd>True if this instance can be used as-is; false if not</dd></dl> 224</li> 225</ul> 226</li> 227</ul> 228</li> 229</ul> 230</div> 231</div> 232<!-- ========= END OF CLASS DATA ========= --> 233<!-- ======= START OF BOTTOM NAVBAR ====== --> 234<div class="bottomNav"><a name="navbar_bottom"> 235<!-- --> 236</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> 237<!-- --> 238</a> 239<ul class="navList" title="Navigation"> 240<li><a href="../../../../com/fasterxml/jackson/annotation/package-summary.html">Package</a></li> 241<li class="navBarCell1Rev">Class</li> 242<li><a href="class-use/ObjectIdResolver.html">Use</a></li> 243<li><a href="package-tree.html">Tree</a></li> 244<li><a href="../../../../deprecated-list.html">Deprecated</a></li> 245<li><a href="../../../../index-all.html">Index</a></li> 246<li><a href="../../../../help-doc.html">Help</a></li> 247</ul> 248</div> 249<div class="subNav"> 250<ul class="navList"> 251<li><a href="../../../../com/fasterxml/jackson/annotation/ObjectIdGenerators.UUIDGenerator.html" title="class in com.fasterxml.jackson.annotation"><span class="strong">Prev Class</span></a></li> 252<li><a href="../../../../com/fasterxml/jackson/annotation/OptBoolean.html" title="enum in com.fasterxml.jackson.annotation"><span class="strong">Next Class</span></a></li> 253</ul> 254<ul class="navList"> 255<li><a href="../../../../index.html?com/fasterxml/jackson/annotation/ObjectIdResolver.html" target="_top">Frames</a></li> 256<li><a href="ObjectIdResolver.html" target="_top">No Frames</a></li> 257</ul> 258<ul class="navList" id="allclasses_navbar_bottom"> 259<li><a href="../../../../allclasses-noframe.html">All Classes</a></li> 260</ul> 261<div> 262<script type="text/javascript"><!-- 263 allClassesLink = document.getElementById("allclasses_navbar_bottom"); 264 if(window==top) { 265 allClassesLink.style.display = "block"; 266 } 267 else { 268 allClassesLink.style.display = "none"; 269 } 270 //--> 271</script> 272</div> 273<div> 274<ul class="subNavList"> 275<li>Summary: </li> 276<li>Nested | </li> 277<li>Field | </li> 278<li>Constr | </li> 279<li><a href="#method_summary">Method</a></li> 280</ul> 281<ul class="subNavList"> 282<li>Detail: </li> 283<li>Field | </li> 284<li>Constr | </li> 285<li><a href="#method_detail">Method</a></li> 286</ul> 287</div> 288<a name="skip-navbar_bottom"> 289<!-- --> 290</a></div> 291<!-- ======== END OF BOTTOM NAVBAR ======= --> 292<p class="legalCopy"><small>Copyright © 2008–2018 <a href="http://fasterxml.com/">FasterXML</a>. All rights reserved.</small></p> 293</body> 294</html> 295