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 Fri Jan 15 20:28:41 PST 2016 --> 6<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 7<title>SerializationFeature (jackson-databind 2.7.0 API)</title> 8<meta name="date" content="2016-01-15"> 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="SerializationFeature (jackson-databind 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="../../../../overview-summary.html">Overview</a></li> 29<li><a href="package-summary.html">Package</a></li> 30<li class="navBarCell1Rev">Class</li> 31<li><a href="class-use/SerializationFeature.html">Use</a></li> 32<li><a href="package-tree.html">Tree</a></li> 33<li><a href="../../../../deprecated-list.html">Deprecated</a></li> 34<li><a href="../../../../index-all.html">Index</a></li> 35<li><a href="../../../../help-doc.html">Help</a></li> 36</ul> 37</div> 38<div class="subNav"> 39<ul class="navList"> 40<li><a href="../../../../com/fasterxml/jackson/databind/SerializationConfig.html" title="class in com.fasterxml.jackson.databind"><span class="strong">Prev Class</span></a></li> 41<li><a href="../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind"><span class="strong">Next Class</span></a></li> 42</ul> 43<ul class="navList"> 44<li><a href="../../../../index.html?com/fasterxml/jackson/databind/SerializationFeature.html" target="_top">Frames</a></li> 45<li><a href="SerializationFeature.html" target="_top">No Frames</a></li> 46</ul> 47<ul class="navList" id="allclasses_navbar_top"> 48<li><a href="../../../../allclasses-noframe.html">All Classes</a></li> 49</ul> 50<div> 51<script type="text/javascript"><!-- 52 allClassesLink = document.getElementById("allclasses_navbar_top"); 53 if(window==top) { 54 allClassesLink.style.display = "block"; 55 } 56 else { 57 allClassesLink.style.display = "none"; 58 } 59 //--> 60</script> 61</div> 62<div> 63<ul class="subNavList"> 64<li>Summary: </li> 65<li>Nested | </li> 66<li><a href="#enum_constant_summary">Enum Constants</a> | </li> 67<li>Field | </li> 68<li><a href="#method_summary">Method</a></li> 69</ul> 70<ul class="subNavList"> 71<li>Detail: </li> 72<li><a href="#enum_constant_detail">Enum Constants</a> | </li> 73<li>Field | </li> 74<li><a href="#method_detail">Method</a></li> 75</ul> 76</div> 77<a name="skip-navbar_top"> 78<!-- --> 79</a></div> 80<!-- ========= END OF TOP NAVBAR ========= --> 81<!-- ======== START OF CLASS DATA ======== --> 82<div class="header"> 83<div class="subTitle">com.fasterxml.jackson.databind</div> 84<h2 title="Enum SerializationFeature" class="title">Enum SerializationFeature</h2> 85</div> 86<div class="contentContainer"> 87<ul class="inheritance"> 88<li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> 89<li> 90<ul class="inheritance"> 91<li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">java.lang.Enum</a><<a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a>></li> 92<li> 93<ul class="inheritance"> 94<li>com.fasterxml.jackson.databind.SerializationFeature</li> 95</ul> 96</li> 97</ul> 98</li> 99</ul> 100<div class="description"> 101<ul class="blockList"> 102<li class="blockList"> 103<dl> 104<dt>All Implemented Interfaces:</dt> 105<dd><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html" title="interface in com.fasterxml.jackson.databind.cfg">ConfigFeature</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</a><<a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a>></dd> 106</dl> 107<hr> 108<br> 109<pre>public enum <span class="strong">SerializationFeature</span> 110extends <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</a><<a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a>> 111implements <a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html" title="interface in com.fasterxml.jackson.databind.cfg">ConfigFeature</a></pre> 112<div class="block">Enumeration that defines simple on/off features that affect 113 the way Java objects are serialized. 114<p> 115 Note that features can be set both through 116 <a href="../../../../com/fasterxml/jackson/databind/ObjectMapper.html" title="class in com.fasterxml.jackson.databind"><code>ObjectMapper</code></a> (as sort of defaults) and through 117 <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a>. 118 In first case these defaults must follow "config-then-use" patterns 119 (i.e. defined once, not changed afterwards); all per-call 120 changes must be done using <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a>.</div> 121</li> 122</ul> 123</div> 124<div class="summary"> 125<ul class="blockList"> 126<li class="blockList"> 127<!-- =========== ENUM CONSTANT SUMMARY =========== --> 128<ul class="blockList"> 129<li class="blockList"><a name="enum_constant_summary"> 130<!-- --> 131</a> 132<h3>Enum Constant Summary</h3> 133<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Enum Constant Summary table, listing enum constants, and an explanation"> 134<caption><span>Enum Constants</span><span class="tabEnd"> </span></caption> 135<tr> 136<th class="colOne" scope="col">Enum Constant and Description</th> 137</tr> 138<tr class="altColor"> 139<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#CLOSE_CLOSEABLE">CLOSE_CLOSEABLE</a></strong></code> 140<div class="block">Feature that determines whether <code>close</code> method of 141 serialized <b>root level</b> objects (ones for which <code>ObjectMapper</code>'s 142 writeValue() (or equivalent) method is called) 143 that implement <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io"><code>Closeable</code></a> 144 is called after serialization or not.</div> 145</td> 146</tr> 147<tr class="rowColor"> 148<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#EAGER_SERIALIZER_FETCH">EAGER_SERIALIZER_FETCH</a></strong></code> 149<div class="block">Feature that determines whether <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a> should 150 try to eagerly fetch necessary <a href="../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind"><code>JsonSerializer</code></a> when 151 possible.</div> 152</td> 153</tr> 154<tr class="altColor"> 155<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#FAIL_ON_EMPTY_BEANS">FAIL_ON_EMPTY_BEANS</a></strong></code> 156<div class="block">Feature that determines what happens when no accessors are 157 found for a type (and there are no annotations to indicate 158 it is meant to be serialized).</div> 159</td> 160</tr> 161<tr class="rowColor"> 162<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#FAIL_ON_SELF_REFERENCES">FAIL_ON_SELF_REFERENCES</a></strong></code> 163<div class="block">Feature that determines what happens when a direct self-reference 164 is detected by a POJO (and no Object Id handling is enabled for it): 165 either a <a href="../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind"><code>JsonMappingException</code></a> is 166 thrown (if true), or reference is normally processed (false).</div> 167</td> 168</tr> 169<tr class="altColor"> 170<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#FAIL_ON_UNWRAPPED_TYPE_IDENTIFIERS">FAIL_ON_UNWRAPPED_TYPE_IDENTIFIERS</a></strong></code> 171<div class="block">Feature that determines what happens when an object which 172 normally has type information included by Jackson is used 173 in conjunction with <a href="http://fasterxml.github.com/jackson-annotations/javadoc/2.7/com/fasterxml/jackson/annotation/JsonUnwrapped.html?is-external=true" title="class or interface in com.fasterxml.jackson.annotation"><code>JsonUnwrapped</code></a>.</div> 174</td> 175</tr> 176<tr class="rowColor"> 177<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#FLUSH_AFTER_WRITE_VALUE">FLUSH_AFTER_WRITE_VALUE</a></strong></code> 178<div class="block">Feature that determines whether <code>JsonGenerator.flush()</code> is 179 called after <code>writeValue()</code> method <b>that takes JsonGenerator 180 as an argument</b> completes (i.e.</div> 181</td> 182</tr> 183<tr class="altColor"> 184<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#INDENT_OUTPUT">INDENT_OUTPUT</a></strong></code> 185<div class="block">Feature that allows enabling (or disabling) indentation 186 for the underlying generator, using the default pretty 187 printer configured for <a href="../../../../com/fasterxml/jackson/databind/ObjectMapper.html" title="class in com.fasterxml.jackson.databind"><code>ObjectMapper</code></a> (and 188 <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a>s created from mapper).</div> 189</td> 190</tr> 191<tr class="rowColor"> 192<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#ORDER_MAP_ENTRIES_BY_KEYS">ORDER_MAP_ENTRIES_BY_KEYS</a></strong></code> 193<div class="block">Feature that determines whether <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a> entries are first 194 sorted by key before serialization or not: if enabled, additional sorting 195 step is performed if necessary (not necessary for <a href="http://docs.oracle.com/javase/7/docs/api/java/util/SortedMap.html?is-external=true" title="class or interface in java.util"><code>SortedMap</code></a>s), 196 if disabled, no additional sorting is needed.</div> 197</td> 198</tr> 199<tr class="altColor"> 200<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#USE_EQUALITY_FOR_OBJECT_ID">USE_EQUALITY_FOR_OBJECT_ID</a></strong></code> 201<div class="block">Feature that determines whether Object Identity is compared using 202 true JVM-level identity of Object (false); or, <code>equals()</code> method.</div> 203</td> 204</tr> 205<tr class="rowColor"> 206<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRAP_EXCEPTIONS">WRAP_EXCEPTIONS</a></strong></code> 207<div class="block">Feature that determines whether Jackson code should catch 208 and wrap <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang"><code>Exception</code></a>s (but never <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Error.html?is-external=true" title="class or interface in java.lang"><code>Error</code></a>s!) 209 to add additional information about 210 location (within input) of problem or not.</div> 211</td> 212</tr> 213<tr class="altColor"> 214<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRAP_ROOT_VALUE">WRAP_ROOT_VALUE</a></strong></code> 215<div class="block">Feature that can be enabled to make root value (usually JSON 216 Object but can be any type) wrapped within a single property 217 JSON object, where key as the "root name", as determined by 218 annotation introspector (esp.</div> 219</td> 220</tr> 221<tr class="rowColor"> 222<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_BIGDECIMAL_AS_PLAIN">WRITE_BIGDECIMAL_AS_PLAIN</a></strong></code> 223<div class="block"><strong>Deprecated.</strong> 224<div class="block"><i>Since 2.5: use <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.Feature.html?is-external=true#WRITE_BIGDECIMAL_AS_PLAIN" title="class or interface in com.fasterxml.jackson.core"><code>JsonGenerator.Feature.WRITE_BIGDECIMAL_AS_PLAIN</code></a> instead 225 (using <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html#with(com.fasterxml.jackson.core.JsonGenerator.Feature)"><code>ObjectWriter.with(com.fasterxml.jackson.core.JsonGenerator.Feature)</code></a>).</i></div> 226</div> 227</td> 228</tr> 229<tr class="altColor"> 230<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_CHAR_ARRAYS_AS_JSON_ARRAYS">WRITE_CHAR_ARRAYS_AS_JSON_ARRAYS</a></strong></code> 231<div class="block">Feature that determines how type <code>char[]</code> is serialized: 232 when enabled, will be serialized as an explict JSON array (with 233 single-character Strings as values); when disabled, defaults to 234 serializing them as Strings (which is more compact).</div> 235</td> 236</tr> 237<tr class="rowColor"> 238<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATE_KEYS_AS_TIMESTAMPS">WRITE_DATE_KEYS_AS_TIMESTAMPS</a></strong></code> 239<div class="block">Feature that determines whether <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Date.html?is-external=true" title="class or interface in java.util"><code>Date</code></a>s 240 (and sub-types) used as <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a> keys are serialized 241 as timestamps or not (if not, will be serialized as textual 242 values).</div> 243</td> 244</tr> 245<tr class="altColor"> 246<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS">WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS</a></strong></code> 247<div class="block">Feature that controls whether numeric timestamp values are 248 to be written using nanosecond timestamps (enabled) or not (disabled); 249 <b>if and only if</b> datatype supports such resolution.</div> 250</td> 251</tr> 252<tr class="rowColor"> 253<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATES_AS_TIMESTAMPS">WRITE_DATES_AS_TIMESTAMPS</a></strong></code> 254<div class="block">Feature that determines whether Date (and date/time) values 255 (and Date-based things like <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Calendar.html?is-external=true" title="class or interface in java.util"><code>Calendar</code></a>s) are to be 256 serialized as numeric timestamps (true; the default), 257 or as something else (usually textual representation).</div> 258</td> 259</tr> 260<tr class="altColor"> 261<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATES_WITH_ZONE_ID">WRITE_DATES_WITH_ZONE_ID</a></strong></code> 262<div class="block">Feature that determines whether date/date-time values should be serialized 263 so that they include timezone id, in cases where type itself contains 264 timezone information.</div> 265</td> 266</tr> 267<tr class="rowColor"> 268<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DURATIONS_AS_TIMESTAMPS">WRITE_DURATIONS_AS_TIMESTAMPS</a></strong></code> 269<div class="block">Feature that determines whether time values that represents time periods 270 (durations, periods, ranges) are to be serialized by default using 271 a numeric (true) or textual (false) representations.</div> 272</td> 273</tr> 274<tr class="altColor"> 275<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_EMPTY_JSON_ARRAYS">WRITE_EMPTY_JSON_ARRAYS</a></strong></code> 276<div class="block">Feature that determines whether Container properties (POJO properties 277 with declared value of Collection or array; i.e.</div> 278</td> 279</tr> 280<tr class="rowColor"> 281<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_ENUMS_USING_INDEX">WRITE_ENUMS_USING_INDEX</a></strong></code> 282<div class="block">Feature that determines whethere Java Enum values are serialized 283 as numbers (true), or textual values (false).</div> 284</td> 285</tr> 286<tr class="altColor"> 287<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_ENUMS_USING_TO_STRING">WRITE_ENUMS_USING_TO_STRING</a></strong></code> 288<div class="block">Feature that determines standard serialization mechanism used for 289 Enum values: if enabled, return value of <code>Enum.toString()</code> 290 is used; if disabled, return value of <code>Enum.name()</code> is used.</div> 291</td> 292</tr> 293<tr class="rowColor"> 294<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_NULL_MAP_VALUES">WRITE_NULL_MAP_VALUES</a></strong></code> 295<div class="block">Feature that determines whether Map entries with null values are 296 to be serialized (true) or not (false).</div> 297</td> 298</tr> 299<tr class="altColor"> 300<td class="colOne"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_SINGLE_ELEM_ARRAYS_UNWRAPPED">WRITE_SINGLE_ELEM_ARRAYS_UNWRAPPED</a></strong></code> 301<div class="block">Feature added for interoperability, to work with oddities of 302 so-called "BadgerFish" convention.</div> 303</td> 304</tr> 305</table> 306</li> 307</ul> 308<!-- ========== METHOD SUMMARY =========== --> 309<ul class="blockList"> 310<li class="blockList"><a name="method_summary"> 311<!-- --> 312</a> 313<h3>Method Summary</h3> 314<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> 315<caption><span>Methods</span><span class="tabEnd"> </span></caption> 316<tr> 317<th class="colFirst" scope="col">Modifier and Type</th> 318<th class="colLast" scope="col">Method and Description</th> 319</tr> 320<tr class="altColor"> 321<td class="colFirst"><code>boolean</code></td> 322<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#enabledByDefault()">enabledByDefault</a></strong>()</code> 323<div class="block">Accessor for checking whether this feature is enabled by default.</div> 324</td> 325</tr> 326<tr class="rowColor"> 327<td class="colFirst"><code>boolean</code></td> 328<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#enabledIn(int)">enabledIn</a></strong>(int flags)</code> 329<div class="block">Convenience method for checking whether feature is enabled in given bitmask</div> 330</td> 331</tr> 332<tr class="altColor"> 333<td class="colFirst"><code>int</code></td> 334<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#getMask()">getMask</a></strong>()</code> 335<div class="block">Returns bit mask for this feature instance</div> 336</td> 337</tr> 338<tr class="rowColor"> 339<td class="colFirst"><code>static <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a></code></td> 340<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#valueOf(java.lang.String)">valueOf</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</code> 341<div class="block">Returns the enum constant of this type with the specified name.</div> 342</td> 343</tr> 344<tr class="altColor"> 345<td class="colFirst"><code>static <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a>[]</code></td> 346<td class="colLast"><code><strong><a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#values()">values</a></strong>()</code> 347<div class="block">Returns an array containing the constants of this enum type, in 348the order they are declared.</div> 349</td> 350</tr> 351</table> 352<ul class="blockList"> 353<li class="blockList"><a name="methods_inherited_from_class_java.lang.Enum"> 354<!-- --> 355</a> 356<h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</a></h3> 357<code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#compareTo(E)" title="class or interface in java.lang">compareTo</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#getDeclaringClass()" title="class or interface in java.lang">getDeclaringClass</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#name()" title="class or interface in java.lang">name</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#ordinal()" title="class or interface in java.lang">ordinal</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Enum.html?is-external=true#valueOf(java.lang.Class,%20java.lang.String)" title="class or interface in java.lang">valueOf</a></code></li> 358</ul> 359<ul class="blockList"> 360<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object"> 361<!-- --> 362</a> 363<h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> 364<code><a href="http://docs.oracle.com/javase/7/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/7/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/7/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/7/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/7/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/7/docs/api/java/lang/Object.html?is-external=true#wait(long,%20int)" title="class or interface in java.lang">wait</a></code></li> 365</ul> 366</li> 367</ul> 368</li> 369</ul> 370</div> 371<div class="details"> 372<ul class="blockList"> 373<li class="blockList"> 374<!-- ============ ENUM CONSTANT DETAIL =========== --> 375<ul class="blockList"> 376<li class="blockList"><a name="enum_constant_detail"> 377<!-- --> 378</a> 379<h3>Enum Constant Detail</h3> 380<a name="WRAP_ROOT_VALUE"> 381<!-- --> 382</a> 383<ul class="blockList"> 384<li class="blockList"> 385<h4>WRAP_ROOT_VALUE</h4> 386<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRAP_ROOT_VALUE</pre> 387<div class="block">Feature that can be enabled to make root value (usually JSON 388 Object but can be any type) wrapped within a single property 389 JSON object, where key as the "root name", as determined by 390 annotation introspector (esp. for JAXB that uses 391 <code>@XmlRootElement.name</code>) or fallback (non-qualified 392 class name). 393 Feature is mostly intended for JAXB compatibility. 394<p> 395 Feature is disabled by default.</div> 396</li> 397</ul> 398<a name="INDENT_OUTPUT"> 399<!-- --> 400</a> 401<ul class="blockList"> 402<li class="blockList"> 403<h4>INDENT_OUTPUT</h4> 404<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> INDENT_OUTPUT</pre> 405<div class="block">Feature that allows enabling (or disabling) indentation 406 for the underlying generator, using the default pretty 407 printer configured for <a href="../../../../com/fasterxml/jackson/databind/ObjectMapper.html" title="class in com.fasterxml.jackson.databind"><code>ObjectMapper</code></a> (and 408 <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a>s created from mapper). 409<p> 410 Note that the default pretty printer is only used if 411 no explicit <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/PrettyPrinter.html?is-external=true" title="class or interface in com.fasterxml.jackson.core"><code>PrettyPrinter</code></a> has been configured 412 for the generator or <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a>. 413<p> 414 Feature is disabled by default.</div> 415</li> 416</ul> 417<a name="FAIL_ON_EMPTY_BEANS"> 418<!-- --> 419</a> 420<ul class="blockList"> 421<li class="blockList"> 422<h4>FAIL_ON_EMPTY_BEANS</h4> 423<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> FAIL_ON_EMPTY_BEANS</pre> 424<div class="block">Feature that determines what happens when no accessors are 425 found for a type (and there are no annotations to indicate 426 it is meant to be serialized). If enabled (default), an 427 exception is thrown to indicate these as non-serializable 428 types; if disabled, they are serialized as empty Objects, 429 i.e. without any properties. 430<p> 431 Note that empty types that this feature has only effect on 432 those "empty" beans that do not have any recognized annotations 433 (like <code>@JsonSerialize</code>): ones that do have annotations 434 do not result in an exception being thrown. 435<p> 436 Feature is enabled by default.</div> 437</li> 438</ul> 439<a name="FAIL_ON_SELF_REFERENCES"> 440<!-- --> 441</a> 442<ul class="blockList"> 443<li class="blockList"> 444<h4>FAIL_ON_SELF_REFERENCES</h4> 445<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> FAIL_ON_SELF_REFERENCES</pre> 446<div class="block">Feature that determines what happens when a direct self-reference 447 is detected by a POJO (and no Object Id handling is enabled for it): 448 either a <a href="../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind"><code>JsonMappingException</code></a> is 449 thrown (if true), or reference is normally processed (false). 450<p> 451 Feature is enabled by default.</div> 452<dl><dt><span class="strong">Since:</span></dt> 453 <dd>2.4</dd></dl> 454</li> 455</ul> 456<a name="WRAP_EXCEPTIONS"> 457<!-- --> 458</a> 459<ul class="blockList"> 460<li class="blockList"> 461<h4>WRAP_EXCEPTIONS</h4> 462<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRAP_EXCEPTIONS</pre> 463<div class="block">Feature that determines whether Jackson code should catch 464 and wrap <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang"><code>Exception</code></a>s (but never <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Error.html?is-external=true" title="class or interface in java.lang"><code>Error</code></a>s!) 465 to add additional information about 466 location (within input) of problem or not. If enabled, 467 most exceptions will be caught and re-thrown (exception 468 specifically being that <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io"><code>IOException</code></a>s may be passed 469 as is, since they are declared as throwable); this can be 470 convenient both in that all exceptions will be checked and 471 declared, and so there is more contextual information. 472 However, sometimes calling application may just want "raw" 473 unchecked exceptions passed as is. 474<p> 475<p> 476 Feature is enabled by default.</div> 477</li> 478</ul> 479<a name="FAIL_ON_UNWRAPPED_TYPE_IDENTIFIERS"> 480<!-- --> 481</a> 482<ul class="blockList"> 483<li class="blockList"> 484<h4>FAIL_ON_UNWRAPPED_TYPE_IDENTIFIERS</h4> 485<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> FAIL_ON_UNWRAPPED_TYPE_IDENTIFIERS</pre> 486<div class="block">Feature that determines what happens when an object which 487 normally has type information included by Jackson is used 488 in conjunction with <a href="http://fasterxml.github.com/jackson-annotations/javadoc/2.7/com/fasterxml/jackson/annotation/JsonUnwrapped.html?is-external=true" title="class or interface in com.fasterxml.jackson.annotation"><code>JsonUnwrapped</code></a>. 489 In the default (enabled) state, an error will be thrown when 490 an unwrapped object has type information. When disabled, the 491 object will be unwrapped and the type information discarded. 492<p> 493 Feature is enabled by default.</div> 494<dl><dt><span class="strong">Since:</span></dt> 495 <dd>2.4</dd></dl> 496</li> 497</ul> 498<a name="CLOSE_CLOSEABLE"> 499<!-- --> 500</a> 501<ul class="blockList"> 502<li class="blockList"> 503<h4>CLOSE_CLOSEABLE</h4> 504<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> CLOSE_CLOSEABLE</pre> 505<div class="block">Feature that determines whether <code>close</code> method of 506 serialized <b>root level</b> objects (ones for which <code>ObjectMapper</code>'s 507 writeValue() (or equivalent) method is called) 508 that implement <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io"><code>Closeable</code></a> 509 is called after serialization or not. If enabled, <b>close()</b> will 510 be called after serialization completes (whether succesfully, or 511 due to an error manifested by an exception being thrown). You can 512 think of this as sort of "finally" processing. 513<p> 514 NOTE: only affects behavior with <b>root</b> objects, and not other 515 objects reachable from the root object. Put another way, only one 516 call will be made for each 'writeValue' call. 517<p> 518 Feature is disabled by default.</div> 519</li> 520</ul> 521<a name="FLUSH_AFTER_WRITE_VALUE"> 522<!-- --> 523</a> 524<ul class="blockList"> 525<li class="blockList"> 526<h4>FLUSH_AFTER_WRITE_VALUE</h4> 527<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> FLUSH_AFTER_WRITE_VALUE</pre> 528<div class="block">Feature that determines whether <code>JsonGenerator.flush()</code> is 529 called after <code>writeValue()</code> method <b>that takes JsonGenerator 530 as an argument</b> completes (i.e. does NOT affect methods 531 that use other destinations); same for methods in <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a>. 532 This usually makes sense; but there are cases where flushing 533 should not be forced: for example when underlying stream is 534 compressing and flush() causes compression state to be flushed 535 (which occurs with some compression codecs). 536<p> 537 Feature is enabled by default.</div> 538</li> 539</ul> 540<a name="WRITE_DATES_AS_TIMESTAMPS"> 541<!-- --> 542</a> 543<ul class="blockList"> 544<li class="blockList"> 545<h4>WRITE_DATES_AS_TIMESTAMPS</h4> 546<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_DATES_AS_TIMESTAMPS</pre> 547<div class="block">Feature that determines whether Date (and date/time) values 548 (and Date-based things like <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Calendar.html?is-external=true" title="class or interface in java.util"><code>Calendar</code></a>s) are to be 549 serialized as numeric timestamps (true; the default), 550 or as something else (usually textual representation). 551 If textual representation is used, the actual format is 552 one returned by a call to 553 <a href="../../../../com/fasterxml/jackson/databind/cfg/MapperConfig.html#getDateFormat()"><code>MapperConfig.getDateFormat()</code></a>: 554 the default setting being <a href="../../../../com/fasterxml/jackson/databind/util/StdDateFormat.html" title="class in com.fasterxml.jackson.databind.util"><code>StdDateFormat</code></a>, 555 which corresponds to format String of "yyyy-MM-dd'T'HH:mm:ss.SSSZ" 556 (see <a href="http://docs.oracle.com/javase/7/docs/api/java/text/DateFormat.html?is-external=true" title="class or interface in java.text"><code>DateFormat</code></a> for details of format Strings). 557<p> 558 Note: whether this feature affects handling of other date-related 559 types depend on handlers of those types, although ideally they 560 should use this feature 561<p> 562 Note: whether <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a> keys are serialized as Strings 563 or not is controlled using <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATE_KEYS_AS_TIMESTAMPS"><code>WRITE_DATE_KEYS_AS_TIMESTAMPS</code></a>. 564<p> 565 Feature is enabled by default, so that date/time are by default 566 serialized as timestamps.</div> 567</li> 568</ul> 569<a name="WRITE_DATE_KEYS_AS_TIMESTAMPS"> 570<!-- --> 571</a> 572<ul class="blockList"> 573<li class="blockList"> 574<h4>WRITE_DATE_KEYS_AS_TIMESTAMPS</h4> 575<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_DATE_KEYS_AS_TIMESTAMPS</pre> 576<div class="block">Feature that determines whether <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Date.html?is-external=true" title="class or interface in java.util"><code>Date</code></a>s 577 (and sub-types) used as <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a> keys are serialized 578 as timestamps or not (if not, will be serialized as textual 579 values). 580<p> 581 Default value is 'false', meaning that Date-valued Map keys are serialized 582 as textual (ISO-8601) values. 583<p> 584 Feature is disabled by default.</div> 585</li> 586</ul> 587<a name="WRITE_DATES_WITH_ZONE_ID"> 588<!-- --> 589</a> 590<ul class="blockList"> 591<li class="blockList"> 592<h4>WRITE_DATES_WITH_ZONE_ID</h4> 593<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_DATES_WITH_ZONE_ID</pre> 594<div class="block">Feature that determines whether date/date-time values should be serialized 595 so that they include timezone id, in cases where type itself contains 596 timezone information. Including this information may lead to compatibility 597 issues because ISO-8601 specification does not define formats that include 598 such information. 599<p> 600 If enabled, Timezone id should be included using format specified 601 with Java 8 <code>DateTimeFormatter#ISO_ZONED_DATE_TIME</code> definition 602 (for example, '2011-12-03T10:15:30+01:00[Europe/Paris]'). 603<p> 604 Note: setting has no relevance if date/time values are serialized as timestamps. 605<p> 606 Feature is disabled by default, so that zone id is NOT included; rather, timezone 607 offset is used for ISO-8601 compatibility (if any timezone information is 608 included in value).</div> 609<dl><dt><span class="strong">Since:</span></dt> 610 <dd>2.6</dd></dl> 611</li> 612</ul> 613<a name="WRITE_DURATIONS_AS_TIMESTAMPS"> 614<!-- --> 615</a> 616<ul class="blockList"> 617<li class="blockList"> 618<h4>WRITE_DURATIONS_AS_TIMESTAMPS</h4> 619<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_DURATIONS_AS_TIMESTAMPS</pre> 620<div class="block">Feature that determines whether time values that represents time periods 621 (durations, periods, ranges) are to be serialized by default using 622 a numeric (true) or textual (false) representations. Note that numeric 623 representation may mean either simple number, or an array of numbers, 624 depending on type. 625<p> 626 Note: whether <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a> keys are serialized as Strings 627 or not is controlled using <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATE_KEYS_AS_TIMESTAMPS"><code>WRITE_DATE_KEYS_AS_TIMESTAMPS</code></a>. 628<p> 629 Feature is enabled by default, so that period/duration are by default 630 serialized as timestamps.</div> 631<dl><dt><span class="strong">Since:</span></dt> 632 <dd>2.5</dd></dl> 633</li> 634</ul> 635<a name="WRITE_CHAR_ARRAYS_AS_JSON_ARRAYS"> 636<!-- --> 637</a> 638<ul class="blockList"> 639<li class="blockList"> 640<h4>WRITE_CHAR_ARRAYS_AS_JSON_ARRAYS</h4> 641<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_CHAR_ARRAYS_AS_JSON_ARRAYS</pre> 642<div class="block">Feature that determines how type <code>char[]</code> is serialized: 643 when enabled, will be serialized as an explict JSON array (with 644 single-character Strings as values); when disabled, defaults to 645 serializing them as Strings (which is more compact). 646<p> 647 Feature is disabled by default.</div> 648</li> 649</ul> 650<a name="WRITE_ENUMS_USING_TO_STRING"> 651<!-- --> 652</a> 653<ul class="blockList"> 654<li class="blockList"> 655<h4>WRITE_ENUMS_USING_TO_STRING</h4> 656<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_ENUMS_USING_TO_STRING</pre> 657<div class="block">Feature that determines standard serialization mechanism used for 658 Enum values: if enabled, return value of <code>Enum.toString()</code> 659 is used; if disabled, return value of <code>Enum.name()</code> is used. 660<p> 661 Note: this feature should usually have same value 662 as <a href="../../../../com/fasterxml/jackson/databind/DeserializationFeature.html#READ_ENUMS_USING_TO_STRING"><code>DeserializationFeature.READ_ENUMS_USING_TO_STRING</code></a>. 663<p> 664 Feature is disabled by default.</div> 665</li> 666</ul> 667<a name="WRITE_ENUMS_USING_INDEX"> 668<!-- --> 669</a> 670<ul class="blockList"> 671<li class="blockList"> 672<h4>WRITE_ENUMS_USING_INDEX</h4> 673<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_ENUMS_USING_INDEX</pre> 674<div class="block">Feature that determines whethere Java Enum values are serialized 675 as numbers (true), or textual values (false). If textual values are 676 used, other settings are also considered. 677 If this feature is enabled, 678 return value of <code>Enum.ordinal()</code> 679 (an integer) will be used as the serialization. 680<p> 681 Note that this feature has precedence over <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_ENUMS_USING_TO_STRING"><code>WRITE_ENUMS_USING_TO_STRING</code></a>, 682 which is only considered if this feature is set to false. 683<p> 684 Feature is disabled by default.</div> 685</li> 686</ul> 687<a name="WRITE_NULL_MAP_VALUES"> 688<!-- --> 689</a> 690<ul class="blockList"> 691<li class="blockList"> 692<h4>WRITE_NULL_MAP_VALUES</h4> 693<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_NULL_MAP_VALUES</pre> 694<div class="block">Feature that determines whether Map entries with null values are 695 to be serialized (true) or not (false). 696<p> 697 Feature is enabled by default.</div> 698</li> 699</ul> 700<a name="WRITE_EMPTY_JSON_ARRAYS"> 701<!-- --> 702</a> 703<ul class="blockList"> 704<li class="blockList"> 705<h4>WRITE_EMPTY_JSON_ARRAYS</h4> 706<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_EMPTY_JSON_ARRAYS</pre> 707<div class="block">Feature that determines whether Container properties (POJO properties 708 with declared value of Collection or array; i.e. things that produce JSON 709 arrays) that are empty (have no elements) 710 will be serialized as empty JSON arrays (true), or suppressed from output (false). 711<p> 712 Note that this does not change behavior of <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a>s, or 713 "Collection-like" types. 714<p> 715 Feature is enabled by default.</div> 716</li> 717</ul> 718<a name="WRITE_SINGLE_ELEM_ARRAYS_UNWRAPPED"> 719<!-- --> 720</a> 721<ul class="blockList"> 722<li class="blockList"> 723<h4>WRITE_SINGLE_ELEM_ARRAYS_UNWRAPPED</h4> 724<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_SINGLE_ELEM_ARRAYS_UNWRAPPED</pre> 725<div class="block">Feature added for interoperability, to work with oddities of 726 so-called "BadgerFish" convention. 727 Feature determines handling of single element <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util"><code>Collection</code></a>s 728 and arrays: if enabled, <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util"><code>Collection</code></a>s and arrays that contain exactly 729 one element will be serialized as if that element itself was serialized. 730<p> 731 When enabled, a POJO with array that normally looks like this: 732<pre> 733 { "arrayProperty" : [ 1 ] } 734</pre> 735 will instead be serialized as 736<pre> 737 { "arrayProperty" : 1 } 738</pre> 739<p> 740 Note that this feature is counterpart to <a href="../../../../com/fasterxml/jackson/databind/DeserializationFeature.html#ACCEPT_SINGLE_VALUE_AS_ARRAY"><code>DeserializationFeature.ACCEPT_SINGLE_VALUE_AS_ARRAY</code></a> 741 (that is, usually both are enabled, or neither is). 742<p> 743 Feature is disabled by default, so that no special handling is done.</div> 744</li> 745</ul> 746<a name="WRITE_BIGDECIMAL_AS_PLAIN"> 747<!-- --> 748</a> 749<ul class="blockList"> 750<li class="blockList"> 751<h4>WRITE_BIGDECIMAL_AS_PLAIN</h4> 752<pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> 753public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_BIGDECIMAL_AS_PLAIN</pre> 754<div class="block"><span class="strong">Deprecated.</span> <i>Since 2.5: use <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.Feature.html?is-external=true#WRITE_BIGDECIMAL_AS_PLAIN" title="class or interface in com.fasterxml.jackson.core"><code>JsonGenerator.Feature.WRITE_BIGDECIMAL_AS_PLAIN</code></a> instead 755 (using <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html#with(com.fasterxml.jackson.core.JsonGenerator.Feature)"><code>ObjectWriter.with(com.fasterxml.jackson.core.JsonGenerator.Feature)</code></a>).</i></div> 756<div class="block">Feature that determines whether <a href="http://docs.oracle.com/javase/7/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><code>BigDecimal</code></a> entries are 757 serialized using <a href="http://docs.oracle.com/javase/7/docs/api/java/math/BigDecimal.html?is-external=true#toPlainString()" title="class or interface in java.math"><code>BigDecimal.toPlainString()</code></a> to prevent 758 values to be written using scientific notation. 759<p> 760 NOTE: since this feature typically requires use of 761 <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true#writeNumber(java.lang.String)" title="class or interface in com.fasterxml.jackson.core"><code>JsonGenerator.writeNumber(String)</code></a> 762 it may cause compatibility problems since not all <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core"><code>JsonGenerator</code></a> 763 implementations support such mode of output: usually only text-based formats 764 support it. 765<p> 766 Feature is disabled by default.</div> 767</li> 768</ul> 769<a name="WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS"> 770<!-- --> 771</a> 772<ul class="blockList"> 773<li class="blockList"> 774<h4>WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS</h4> 775<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS</pre> 776<div class="block">Feature that controls whether numeric timestamp values are 777 to be written using nanosecond timestamps (enabled) or not (disabled); 778 <b>if and only if</b> datatype supports such resolution. 779 Only newer datatypes (such as Java8 Date/Time) support such resolution -- 780 older types (pre-Java8 <b>java.util.Date</b> etc) and Joda do not -- 781 and this setting <b>has no effect</b> on such types. 782<p> 783 If disabled, standard millisecond timestamps are assumed. 784 This is the counterpart to <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html#WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS"><code>WRITE_DATE_TIMESTAMPS_AS_NANOSECONDS</code></a>. 785<p> 786 Feature is enabled by default, to support most accurate time values possible.</div> 787<dl><dt><span class="strong">Since:</span></dt> 788 <dd>2.2</dd></dl> 789</li> 790</ul> 791<a name="ORDER_MAP_ENTRIES_BY_KEYS"> 792<!-- --> 793</a> 794<ul class="blockList"> 795<li class="blockList"> 796<h4>ORDER_MAP_ENTRIES_BY_KEYS</h4> 797<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> ORDER_MAP_ENTRIES_BY_KEYS</pre> 798<div class="block">Feature that determines whether <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><code>Map</code></a> entries are first 799 sorted by key before serialization or not: if enabled, additional sorting 800 step is performed if necessary (not necessary for <a href="http://docs.oracle.com/javase/7/docs/api/java/util/SortedMap.html?is-external=true" title="class or interface in java.util"><code>SortedMap</code></a>s), 801 if disabled, no additional sorting is needed. 802<p> 803 Feature is disabled by default.</div> 804</li> 805</ul> 806<a name="EAGER_SERIALIZER_FETCH"> 807<!-- --> 808</a> 809<ul class="blockList"> 810<li class="blockList"> 811<h4>EAGER_SERIALIZER_FETCH</h4> 812<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> EAGER_SERIALIZER_FETCH</pre> 813<div class="block">Feature that determines whether <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a> should 814 try to eagerly fetch necessary <a href="../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind"><code>JsonSerializer</code></a> when 815 possible. This improves performance in cases where similarly 816 configured <a href="../../../../com/fasterxml/jackson/databind/ObjectWriter.html" title="class in com.fasterxml.jackson.databind"><code>ObjectWriter</code></a> instance is used multiple 817 times; and should not significantly affect single-use cases. 818<p> 819 Note that there should not be any need to normally disable this 820 feature: only consider that if there are actual perceived problems. 821<p> 822 Feature is enabled by default.</div> 823<dl><dt><span class="strong">Since:</span></dt> 824 <dd>2.1</dd></dl> 825</li> 826</ul> 827<a name="USE_EQUALITY_FOR_OBJECT_ID"> 828<!-- --> 829</a> 830<ul class="blockListLast"> 831<li class="blockList"> 832<h4>USE_EQUALITY_FOR_OBJECT_ID</h4> 833<pre>public static final <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> USE_EQUALITY_FOR_OBJECT_ID</pre> 834<div class="block">Feature that determines whether Object Identity is compared using 835 true JVM-level identity of Object (false); or, <code>equals()</code> method. 836 Latter is sometimes useful when dealing with Database-bound objects with 837 ORM libraries (like Hibernate). Note that Object itself is actually compared, 838 and NOT Object Id; naming of this feature is somewhat confusing, so it is important 839 that Object <b>for which identity is to be preserved</b> are considered equal, 840 above and beyond ids (which are always compared using equality anyway). 841<p> 842 NOTE: due to the way functionality is implemented, it is very important that 843 in addition to overriding <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang"><code>Object.equals(java.lang.Object)</code></a> for Objects to match (to be considered 844 "same") it is also necessary to ensure that <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang"><code>Object.hashCode()</code></a> is overridden 845 to produce the exact same value for equal instances. 846<p> 847 Feature is disabled by default; meaning that strict identity is used, not 848 <code>equals()</code></div> 849<dl><dt><span class="strong">Since:</span></dt> 850 <dd>2.3</dd></dl> 851</li> 852</ul> 853</li> 854</ul> 855<!-- ============ METHOD DETAIL ========== --> 856<ul class="blockList"> 857<li class="blockList"><a name="method_detail"> 858<!-- --> 859</a> 860<h3>Method Detail</h3> 861<a name="values()"> 862<!-- --> 863</a> 864<ul class="blockList"> 865<li class="blockList"> 866<h4>values</h4> 867<pre>public static <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a>[] values()</pre> 868<div class="block">Returns an array containing the constants of this enum type, in 869the order they are declared. This method may be used to iterate 870over the constants as follows: 871<pre> 872for (SerializationFeature c : SerializationFeature.values()) 873 System.out.println(c); 874</pre></div> 875<dl><dt><span class="strong">Returns:</span></dt><dd>an array containing the constants of this enum type, in the order they are declared</dd></dl> 876</li> 877</ul> 878<a name="valueOf(java.lang.String)"> 879<!-- --> 880</a> 881<ul class="blockList"> 882<li class="blockList"> 883<h4>valueOf</h4> 884<pre>public static <a href="../../../../com/fasterxml/jackson/databind/SerializationFeature.html" title="enum in com.fasterxml.jackson.databind">SerializationFeature</a> valueOf(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> name)</pre> 885<div class="block">Returns the enum constant of this type with the specified name. 886The string must match <i>exactly</i> an identifier used to declare an 887enum constant in this type. (Extraneous whitespace characters are 888not permitted.)</div> 889<dl><dt><span class="strong">Parameters:</span></dt><dd><code>name</code> - the name of the enum constant to be returned.</dd> 890<dt><span class="strong">Returns:</span></dt><dd>the enum constant with the specified name</dd> 891<dt><span class="strong">Throws:</span></dt> 892<dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</a></code> - if this enum type has no constant with the specified name</dd> 893<dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the argument is null</dd></dl> 894</li> 895</ul> 896<a name="enabledByDefault()"> 897<!-- --> 898</a> 899<ul class="blockList"> 900<li class="blockList"> 901<h4>enabledByDefault</h4> 902<pre>public boolean enabledByDefault()</pre> 903<div class="block"><strong>Description copied from interface: <code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html#enabledByDefault()">ConfigFeature</a></code></strong></div> 904<div class="block">Accessor for checking whether this feature is enabled by default.</div> 905<dl> 906<dt><strong>Specified by:</strong></dt> 907<dd><code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html#enabledByDefault()">enabledByDefault</a></code> in interface <code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html" title="interface in com.fasterxml.jackson.databind.cfg">ConfigFeature</a></code></dd> 908</dl> 909</li> 910</ul> 911<a name="getMask()"> 912<!-- --> 913</a> 914<ul class="blockList"> 915<li class="blockList"> 916<h4>getMask</h4> 917<pre>public int getMask()</pre> 918<div class="block"><strong>Description copied from interface: <code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html#getMask()">ConfigFeature</a></code></strong></div> 919<div class="block">Returns bit mask for this feature instance</div> 920<dl> 921<dt><strong>Specified by:</strong></dt> 922<dd><code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html#getMask()">getMask</a></code> in interface <code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html" title="interface in com.fasterxml.jackson.databind.cfg">ConfigFeature</a></code></dd> 923</dl> 924</li> 925</ul> 926<a name="enabledIn(int)"> 927<!-- --> 928</a> 929<ul class="blockListLast"> 930<li class="blockList"> 931<h4>enabledIn</h4> 932<pre>public boolean enabledIn(int flags)</pre> 933<div class="block"><strong>Description copied from interface: <code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html#enabledIn(int)">ConfigFeature</a></code></strong></div> 934<div class="block">Convenience method for checking whether feature is enabled in given bitmask</div> 935<dl> 936<dt><strong>Specified by:</strong></dt> 937<dd><code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html#enabledIn(int)">enabledIn</a></code> in interface <code><a href="../../../../com/fasterxml/jackson/databind/cfg/ConfigFeature.html" title="interface in com.fasterxml.jackson.databind.cfg">ConfigFeature</a></code></dd> 938</dl> 939</li> 940</ul> 941</li> 942</ul> 943</li> 944</ul> 945</div> 946</div> 947<!-- ========= END OF CLASS DATA ========= --> 948<!-- ======= START OF BOTTOM NAVBAR ====== --> 949<div class="bottomNav"><a name="navbar_bottom"> 950<!-- --> 951</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> 952<!-- --> 953</a> 954<ul class="navList" title="Navigation"> 955<li><a href="../../../../overview-summary.html">Overview</a></li> 956<li><a href="package-summary.html">Package</a></li> 957<li class="navBarCell1Rev">Class</li> 958<li><a href="class-use/SerializationFeature.html">Use</a></li> 959<li><a href="package-tree.html">Tree</a></li> 960<li><a href="../../../../deprecated-list.html">Deprecated</a></li> 961<li><a href="../../../../index-all.html">Index</a></li> 962<li><a href="../../../../help-doc.html">Help</a></li> 963</ul> 964</div> 965<div class="subNav"> 966<ul class="navList"> 967<li><a href="../../../../com/fasterxml/jackson/databind/SerializationConfig.html" title="class in com.fasterxml.jackson.databind"><span class="strong">Prev Class</span></a></li> 968<li><a href="../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind"><span class="strong">Next Class</span></a></li> 969</ul> 970<ul class="navList"> 971<li><a href="../../../../index.html?com/fasterxml/jackson/databind/SerializationFeature.html" target="_top">Frames</a></li> 972<li><a href="SerializationFeature.html" target="_top">No Frames</a></li> 973</ul> 974<ul class="navList" id="allclasses_navbar_bottom"> 975<li><a href="../../../../allclasses-noframe.html">All Classes</a></li> 976</ul> 977<div> 978<script type="text/javascript"><!-- 979 allClassesLink = document.getElementById("allclasses_navbar_bottom"); 980 if(window==top) { 981 allClassesLink.style.display = "block"; 982 } 983 else { 984 allClassesLink.style.display = "none"; 985 } 986 //--> 987</script> 988</div> 989<div> 990<ul class="subNavList"> 991<li>Summary: </li> 992<li>Nested | </li> 993<li><a href="#enum_constant_summary">Enum Constants</a> | </li> 994<li>Field | </li> 995<li><a href="#method_summary">Method</a></li> 996</ul> 997<ul class="subNavList"> 998<li>Detail: </li> 999<li><a href="#enum_constant_detail">Enum Constants</a> | </li> 1000<li>Field | </li> 1001<li><a href="#method_detail">Method</a></li> 1002</ul> 1003</div> 1004<a name="skip-navbar_bottom"> 1005<!-- --> 1006</a></div> 1007<!-- ======== END OF BOTTOM NAVBAR ======= --> 1008<p class="legalCopy"><small>Copyright © 2008–2016 <a href="http://fasterxml.com/">FasterXML</a>. All rights reserved.</small></p> 1009</body> 1010</html> 1011