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_10-ea) on Sun Jul 14 20:03:21 PDT 2013 --> 6<title>ObjectCodec (Jackson JSON Processor)</title> 7<meta name="date" content="2013-07-14"> 8<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style"> 9</head> 10<body> 11<script type="text/javascript"><!-- 12 if (location.href.indexOf('is-external=true') == -1) { 13 parent.document.title="ObjectCodec (Jackson JSON Processor)"; 14 } 15//--> 16</script> 17<noscript> 18<div>JavaScript is disabled on your browser.</div> 19</noscript> 20<!-- ========= START OF TOP NAVBAR ======= --> 21<div class="topNav"><a name="navbar_top"> 22<!-- --> 23</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> 24<!-- --> 25</a> 26<ul class="navList" title="Navigation"> 27<li><a href="../../../overview-summary.html">Overview</a></li> 28<li><a href="package-summary.html">Package</a></li> 29<li class="navBarCell1Rev">Class</li> 30<li><a href="class-use/ObjectCodec.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="../../../org/codehaus/jackson/JsonToken.html" title="enum in org.codehaus.jackson"><span class="strong">Prev Class</span></a></li> 40<li><a href="../../../org/codehaus/jackson/PrettyPrinter.html" title="interface in org.codehaus.jackson"><span class="strong">Next Class</span></a></li> 41</ul> 42<ul class="navList"> 43<li><a href="../../../index.html?org/codehaus/jackson/ObjectCodec.html" target="_top">Frames</a></li> 44<li><a href="ObjectCodec.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><a href="#constructor_summary">Constr</a> | </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><a href="#constructor_detail">Constr</a> | </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">org.codehaus.jackson</div> 83<h2 title="Class ObjectCodec" class="title">Class ObjectCodec</h2> 84</div> 85<div class="contentContainer"> 86<ul class="inheritance"> 87<li><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> 88<li> 89<ul class="inheritance"> 90<li>org.codehaus.jackson.ObjectCodec</li> 91</ul> 92</li> 93</ul> 94<div class="description"> 95<ul class="blockList"> 96<li class="blockList"> 97<dl> 98<dt>Direct Known Subclasses:</dt> 99<dd><a href="../../../org/codehaus/jackson/map/ObjectMapper.html" title="class in org.codehaus.jackson.map">ObjectMapper</a>, <a href="../../../org/codehaus/jackson/map/ObjectReader.html" title="class in org.codehaus.jackson.map">ObjectReader</a></dd> 100</dl> 101<hr> 102<br> 103<pre>public abstract class <span class="strong">ObjectCodec</span> 104extends <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></pre> 105<div class="block">Abstract class that defines the interface that <a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson"><code>JsonParser</code></a> and 106 <a href="../../../org/codehaus/jackson/JsonGenerator.html" title="class in org.codehaus.jackson"><code>JsonGenerator</code></a> use to serialize and deserialize regular 107 Java objects (POJOs aka Beans). 108<p> 109 The standard implementation of this class is 110 <a href="../../../org/codehaus/jackson/map/ObjectMapper.html" title="class in org.codehaus.jackson.map"><code>ObjectMapper</code></a>.</div> 111</li> 112</ul> 113</div> 114<div class="summary"> 115<ul class="blockList"> 116<li class="blockList"> 117<!-- ======== CONSTRUCTOR SUMMARY ======== --> 118<ul class="blockList"> 119<li class="blockList"><a name="constructor_summary"> 120<!-- --> 121</a> 122<h3>Constructor Summary</h3> 123<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> 124<caption><span>Constructors</span><span class="tabEnd"> </span></caption> 125<tr> 126<th class="colFirst" scope="col">Modifier</th> 127<th class="colLast" scope="col">Constructor and Description</th> 128</tr> 129<tr class="altColor"> 130<td class="colFirst"><code>protected </code></td> 131<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#ObjectCodec()">ObjectCodec</a></strong>()</code> </td> 132</tr> 133</table> 134</li> 135</ul> 136<!-- ========== METHOD SUMMARY =========== --> 137<ul class="blockList"> 138<li class="blockList"><a name="method_summary"> 139<!-- --> 140</a> 141<h3>Method Summary</h3> 142<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> 143<caption><span>Methods</span><span class="tabEnd"> </span></caption> 144<tr> 145<th class="colFirst" scope="col">Modifier and Type</th> 146<th class="colLast" scope="col">Method and Description</th> 147</tr> 148<tr class="altColor"> 149<td class="colFirst"><code>abstract <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a></code></td> 150<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#createArrayNode()">createArrayNode</a></strong>()</code> 151<div class="block">Method for construct root level Array nodes 152 for Tree Model instances.</div> 153</td> 154</tr> 155<tr class="rowColor"> 156<td class="colFirst"><code>abstract <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a></code></td> 157<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#createObjectNode()">createObjectNode</a></strong>()</code> 158<div class="block">Method for construct root level Object nodes 159 for Tree Model instances.</div> 160</td> 161</tr> 162<tr class="altColor"> 163<td class="colFirst"><code>abstract <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a></code></td> 164<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readTree(org.codehaus.jackson.JsonParser)">readTree</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp)</code> 165<div class="block">Method to deserialize JSON content as tree expressed 166 using set of <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson"><code>JsonNode</code></a> instances.</div> 167</td> 168</tr> 169<tr class="rowColor"> 170<td class="colFirst"><code>abstract <T> T</code></td> 171<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readValue(org.codehaus.jackson.JsonParser, java.lang.Class)">readValue</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 172 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a><T> valueType)</code> 173<div class="block">Method to deserialize JSON content into a non-container 174 type (it can be an array type, however): typically a bean, array 175 or a wrapper type (like <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang"><code>Boolean</code></a>).</div> 176</td> 177</tr> 178<tr class="altColor"> 179<td class="colFirst"><code>abstract <T> T</code></td> 180<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readValue(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.JavaType)">readValue</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 181 <a href="../../../org/codehaus/jackson/type/JavaType.html" title="class in org.codehaus.jackson.type">JavaType</a> valueType)</code> 182<div class="block">Method to deserialize JSON content as tree expressed 183 using set of <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson"><code>JsonNode</code></a> instances.</div> 184</td> 185</tr> 186<tr class="rowColor"> 187<td class="colFirst"><code>abstract <T> T</code></td> 188<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readValue(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.TypeReference)">readValue</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 189 <a href="../../../org/codehaus/jackson/type/TypeReference.html" title="class in org.codehaus.jackson.type">TypeReference</a><?> valueTypeRef)</code> 190<div class="block">Method to deserialize JSON content into a Java type, reference 191 to which is passed as argument.</div> 192</td> 193</tr> 194<tr class="altColor"> 195<td class="colFirst"><code>abstract <T> <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a><T></code></td> 196<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readValues(org.codehaus.jackson.JsonParser, java.lang.Class)">readValues</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 197 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a><T> valueType)</code> 198<div class="block">Method for reading sequence of Objects from parser stream, 199 all with same specified value type.</div> 200</td> 201</tr> 202<tr class="rowColor"> 203<td class="colFirst"><code>abstract <T> <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a><T></code></td> 204<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readValues(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.JavaType)">readValues</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 205 <a href="../../../org/codehaus/jackson/type/JavaType.html" title="class in org.codehaus.jackson.type">JavaType</a> valueType)</code> 206<div class="block">Method for reading sequence of Objects from parser stream, 207 all with same specified value type.</div> 208</td> 209</tr> 210<tr class="altColor"> 211<td class="colFirst"><code>abstract <T> <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a><T></code></td> 212<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#readValues(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.TypeReference)">readValues</a></strong>(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 213 <a href="../../../org/codehaus/jackson/type/TypeReference.html" title="class in org.codehaus.jackson.type">TypeReference</a><?> valueTypeRef)</code> 214<div class="block">Method for reading sequence of Objects from parser stream, 215 all with same specified value type.</div> 216</td> 217</tr> 218<tr class="rowColor"> 219<td class="colFirst"><code>abstract <a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a></code></td> 220<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#treeAsTokens(org.codehaus.jackson.JsonNode)">treeAsTokens</a></strong>(<a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> n)</code> 221<div class="block">Method for constructing a <a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson"><code>JsonParser</code></a> for reading 222 contents of a JSON tree, as if it was external serialized 223 JSON content.</div> 224</td> 225</tr> 226<tr class="altColor"> 227<td class="colFirst"><code>abstract <T> T</code></td> 228<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#treeToValue(org.codehaus.jackson.JsonNode, java.lang.Class)">treeToValue</a></strong>(<a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> n, 229 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a><T> valueType)</code> 230<div class="block">Convenience method for converting given JSON tree into instance of specified 231 value type.</div> 232</td> 233</tr> 234<tr class="rowColor"> 235<td class="colFirst"><code>abstract void</code></td> 236<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#writeTree(org.codehaus.jackson.JsonGenerator, org.codehaus.jackson.JsonNode)">writeTree</a></strong>(<a href="../../../org/codehaus/jackson/JsonGenerator.html" title="class in org.codehaus.jackson">JsonGenerator</a> jgen, 237 <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> rootNode)</code> 238<div class="block">Method to serialize given Json Tree, using generator 239 provided.</div> 240</td> 241</tr> 242<tr class="altColor"> 243<td class="colFirst"><code>abstract void</code></td> 244<td class="colLast"><code><strong><a href="../../../org/codehaus/jackson/ObjectCodec.html#writeValue(org.codehaus.jackson.JsonGenerator, java.lang.Object)">writeValue</a></strong>(<a href="../../../org/codehaus/jackson/JsonGenerator.html" title="class in org.codehaus.jackson">JsonGenerator</a> jgen, 245 <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> value)</code> 246<div class="block">Method to serialize given Java Object, using generator 247 provided.</div> 248</td> 249</tr> 250</table> 251<ul class="blockList"> 252<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object"> 253<!-- --> 254</a> 255<h3>Methods inherited from class java.lang.<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></h3> 256<code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</a></code></li> 257</ul> 258</li> 259</ul> 260</li> 261</ul> 262</div> 263<div class="details"> 264<ul class="blockList"> 265<li class="blockList"> 266<!-- ========= CONSTRUCTOR DETAIL ======== --> 267<ul class="blockList"> 268<li class="blockList"><a name="constructor_detail"> 269<!-- --> 270</a> 271<h3>Constructor Detail</h3> 272<a name="ObjectCodec()"> 273<!-- --> 274</a> 275<ul class="blockListLast"> 276<li class="blockList"> 277<h4>ObjectCodec</h4> 278<pre>protected ObjectCodec()</pre> 279</li> 280</ul> 281</li> 282</ul> 283<!-- ============ METHOD DETAIL ========== --> 284<ul class="blockList"> 285<li class="blockList"><a name="method_detail"> 286<!-- --> 287</a> 288<h3>Method Detail</h3> 289<a name="readValue(org.codehaus.jackson.JsonParser, java.lang.Class)"> 290<!-- --> 291</a> 292<ul class="blockList"> 293<li class="blockList"> 294<h4>readValue</h4> 295<pre>public abstract <T> T readValue(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 296 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a><T> valueType) 297 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 298 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 299<div class="block">Method to deserialize JSON content into a non-container 300 type (it can be an array type, however): typically a bean, array 301 or a wrapper type (like <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang"><code>Boolean</code></a>). 302<p> 303 Note: this method should NOT be used if the result type is a 304 container (<a href="http://docs.oracle.com/javase/6/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util"><code>Collection</code></a> or <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a>. 305 The reason is that due to type erasure, key and value types 306 can not be introspected when using this method.</div> 307<dl><dt><span class="strong">Throws:</span></dt> 308<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 309<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd></dl> 310</li> 311</ul> 312<a name="readValue(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.TypeReference)"> 313<!-- --> 314</a> 315<ul class="blockList"> 316<li class="blockList"> 317<h4>readValue</h4> 318<pre>public abstract <T> T readValue(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 319 <a href="../../../org/codehaus/jackson/type/TypeReference.html" title="class in org.codehaus.jackson.type">TypeReference</a><?> valueTypeRef) 320 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 321 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 322<div class="block">Method to deserialize JSON content into a Java type, reference 323 to which is passed as argument. Type is passed using so-called 324 "super type token" 325 and specifically needs to be used if the root type is a 326 parameterized (generic) container type.</div> 327<dl><dt><span class="strong">Throws:</span></dt> 328<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 329<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd></dl> 330</li> 331</ul> 332<a name="readValue(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.JavaType)"> 333<!-- --> 334</a> 335<ul class="blockList"> 336<li class="blockList"> 337<h4>readValue</h4> 338<pre>public abstract <T> T readValue(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 339 <a href="../../../org/codehaus/jackson/type/JavaType.html" title="class in org.codehaus.jackson.type">JavaType</a> valueType) 340 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 341 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 342<div class="block">Method to deserialize JSON content as tree expressed 343 using set of <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson"><code>JsonNode</code></a> instances. Returns 344 root of the resulting tree (where root can consist 345 of just a single node if the current event is a 346 value event, not container).</div> 347<dl><dt><span class="strong">Throws:</span></dt> 348<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 349<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd></dl> 350</li> 351</ul> 352<a name="readTree(org.codehaus.jackson.JsonParser)"> 353<!-- --> 354</a> 355<ul class="blockList"> 356<li class="blockList"> 357<h4>readTree</h4> 358<pre>public abstract <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> readTree(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp) 359 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 360 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 361<div class="block">Method to deserialize JSON content as tree expressed 362 using set of <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson"><code>JsonNode</code></a> instances. Returns 363 root of the resulting tree (where root can consist 364 of just a single node if the current event is a 365 value event, not container).</div> 366<dl><dt><span class="strong">Throws:</span></dt> 367<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 368<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd></dl> 369</li> 370</ul> 371<a name="readValues(org.codehaus.jackson.JsonParser, java.lang.Class)"> 372<!-- --> 373</a> 374<ul class="blockList"> 375<li class="blockList"> 376<h4>readValues</h4> 377<pre>public abstract <T> <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a><T> readValues(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 378 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a><T> valueType) 379 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 380 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 381<div class="block">Method for reading sequence of Objects from parser stream, 382 all with same specified value type.</div> 383<dl><dt><span class="strong">Throws:</span></dt> 384<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 385<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd><dt><span class="strong">Since:</span></dt> 386 <dd>1.9</dd></dl> 387</li> 388</ul> 389<a name="readValues(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.TypeReference)"> 390<!-- --> 391</a> 392<ul class="blockList"> 393<li class="blockList"> 394<h4>readValues</h4> 395<pre>public abstract <T> <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a><T> readValues(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 396 <a href="../../../org/codehaus/jackson/type/TypeReference.html" title="class in org.codehaus.jackson.type">TypeReference</a><?> valueTypeRef) 397 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 398 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 399<div class="block">Method for reading sequence of Objects from parser stream, 400 all with same specified value type.</div> 401<dl><dt><span class="strong">Throws:</span></dt> 402<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 403<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd><dt><span class="strong">Since:</span></dt> 404 <dd>1.9</dd></dl> 405</li> 406</ul> 407<a name="readValues(org.codehaus.jackson.JsonParser, org.codehaus.jackson.type.JavaType)"> 408<!-- --> 409</a> 410<ul class="blockList"> 411<li class="blockList"> 412<h4>readValues</h4> 413<pre>public abstract <T> <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a><T> readValues(<a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> jp, 414 <a href="../../../org/codehaus/jackson/type/JavaType.html" title="class in org.codehaus.jackson.type">JavaType</a> valueType) 415 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 416 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 417<div class="block">Method for reading sequence of Objects from parser stream, 418 all with same specified value type.</div> 419<dl><dt><span class="strong">Throws:</span></dt> 420<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 421<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd><dt><span class="strong">Since:</span></dt> 422 <dd>1.9</dd></dl> 423</li> 424</ul> 425<a name="writeValue(org.codehaus.jackson.JsonGenerator, java.lang.Object)"> 426<!-- --> 427</a> 428<ul class="blockList"> 429<li class="blockList"> 430<h4>writeValue</h4> 431<pre>public abstract void writeValue(<a href="../../../org/codehaus/jackson/JsonGenerator.html" title="class in org.codehaus.jackson">JsonGenerator</a> jgen, 432 <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> value) 433 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 434 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 435<div class="block">Method to serialize given Java Object, using generator 436 provided.</div> 437<dl><dt><span class="strong">Throws:</span></dt> 438<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 439<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd></dl> 440</li> 441</ul> 442<a name="writeTree(org.codehaus.jackson.JsonGenerator, org.codehaus.jackson.JsonNode)"> 443<!-- --> 444</a> 445<ul class="blockList"> 446<li class="blockList"> 447<h4>writeTree</h4> 448<pre>public abstract void writeTree(<a href="../../../org/codehaus/jackson/JsonGenerator.html" title="class in org.codehaus.jackson">JsonGenerator</a> jgen, 449 <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> rootNode) 450 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 451 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 452<div class="block">Method to serialize given Json Tree, using generator 453 provided.</div> 454<dl><dt><span class="strong">Throws:</span></dt> 455<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 456<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd></dl> 457</li> 458</ul> 459<a name="createObjectNode()"> 460<!-- --> 461</a> 462<ul class="blockList"> 463<li class="blockList"> 464<h4>createObjectNode</h4> 465<pre>public abstract <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> createObjectNode()</pre> 466<div class="block">Method for construct root level Object nodes 467 for Tree Model instances.</div> 468<dl><dt><span class="strong">Since:</span></dt> 469 <dd>1.2</dd></dl> 470</li> 471</ul> 472<a name="createArrayNode()"> 473<!-- --> 474</a> 475<ul class="blockList"> 476<li class="blockList"> 477<h4>createArrayNode</h4> 478<pre>public abstract <a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> createArrayNode()</pre> 479<div class="block">Method for construct root level Array nodes 480 for Tree Model instances.</div> 481<dl><dt><span class="strong">Since:</span></dt> 482 <dd>1.2</dd></dl> 483</li> 484</ul> 485<a name="treeAsTokens(org.codehaus.jackson.JsonNode)"> 486<!-- --> 487</a> 488<ul class="blockList"> 489<li class="blockList"> 490<h4>treeAsTokens</h4> 491<pre>public abstract <a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson">JsonParser</a> treeAsTokens(<a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> n)</pre> 492<div class="block">Method for constructing a <a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson"><code>JsonParser</code></a> for reading 493 contents of a JSON tree, as if it was external serialized 494 JSON content.</div> 495<dl><dt><span class="strong">Since:</span></dt> 496 <dd>1.3</dd></dl> 497</li> 498</ul> 499<a name="treeToValue(org.codehaus.jackson.JsonNode, java.lang.Class)"> 500<!-- --> 501</a> 502<ul class="blockListLast"> 503<li class="blockList"> 504<h4>treeToValue</h4> 505<pre>public abstract <T> T treeToValue(<a href="../../../org/codehaus/jackson/JsonNode.html" title="class in org.codehaus.jackson">JsonNode</a> n, 506 <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a><T> valueType) 507 throws <a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a>, 508 <a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></pre> 509<div class="block">Convenience method for converting given JSON tree into instance of specified 510 value type. This is equivalent to first constructing a <a href="../../../org/codehaus/jackson/JsonParser.html" title="class in org.codehaus.jackson"><code>JsonParser</code></a> to 511 iterate over contents of the tree, and using that parser for data binding.</div> 512<dl><dt><span class="strong">Throws:</span></dt> 513<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd> 514<dd><code><a href="../../../org/codehaus/jackson/JsonProcessingException.html" title="class in org.codehaus.jackson">JsonProcessingException</a></code></dd><dt><span class="strong">Since:</span></dt> 515 <dd>1.3</dd></dl> 516</li> 517</ul> 518</li> 519</ul> 520</li> 521</ul> 522</div> 523</div> 524<!-- ========= END OF CLASS DATA ========= --> 525<!-- ======= START OF BOTTOM NAVBAR ====== --> 526<div class="bottomNav"><a name="navbar_bottom"> 527<!-- --> 528</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> 529<!-- --> 530</a> 531<ul class="navList" title="Navigation"> 532<li><a href="../../../overview-summary.html">Overview</a></li> 533<li><a href="package-summary.html">Package</a></li> 534<li class="navBarCell1Rev">Class</li> 535<li><a href="class-use/ObjectCodec.html">Use</a></li> 536<li><a href="package-tree.html">Tree</a></li> 537<li><a href="../../../deprecated-list.html">Deprecated</a></li> 538<li><a href="../../../index-all.html">Index</a></li> 539<li><a href="../../../help-doc.html">Help</a></li> 540</ul> 541</div> 542<div class="subNav"> 543<ul class="navList"> 544<li><a href="../../../org/codehaus/jackson/JsonToken.html" title="enum in org.codehaus.jackson"><span class="strong">Prev Class</span></a></li> 545<li><a href="../../../org/codehaus/jackson/PrettyPrinter.html" title="interface in org.codehaus.jackson"><span class="strong">Next Class</span></a></li> 546</ul> 547<ul class="navList"> 548<li><a href="../../../index.html?org/codehaus/jackson/ObjectCodec.html" target="_top">Frames</a></li> 549<li><a href="ObjectCodec.html" target="_top">No Frames</a></li> 550</ul> 551<ul class="navList" id="allclasses_navbar_bottom"> 552<li><a href="../../../allclasses-noframe.html">All Classes</a></li> 553</ul> 554<div> 555<script type="text/javascript"><!-- 556 allClassesLink = document.getElementById("allclasses_navbar_bottom"); 557 if(window==top) { 558 allClassesLink.style.display = "block"; 559 } 560 else { 561 allClassesLink.style.display = "none"; 562 } 563 //--> 564</script> 565</div> 566<div> 567<ul class="subNavList"> 568<li>Summary: </li> 569<li>Nested | </li> 570<li>Field | </li> 571<li><a href="#constructor_summary">Constr</a> | </li> 572<li><a href="#method_summary">Method</a></li> 573</ul> 574<ul class="subNavList"> 575<li>Detail: </li> 576<li>Field | </li> 577<li><a href="#constructor_detail">Constr</a> | </li> 578<li><a href="#method_detail">Method</a></li> 579</ul> 580</div> 581<a name="skip-navbar_bottom"> 582<!-- --> 583</a></div> 584<!-- ======== END OF BOTTOM NAVBAR ======= --> 585</body> 586</html> 587