• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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:23 PDT 2013 -->
6<title>CharacterEscapes (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="CharacterEscapes (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/CharacterEscapes.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>Prev Class</li>
40<li><a href="../../../../org/codehaus/jackson/io/InputDecorator.html" title="class in org.codehaus.jackson.io"><span class="strong">Next Class</span></a></li>
41</ul>
42<ul class="navList">
43<li><a href="../../../../index.html?org/codehaus/jackson/io/CharacterEscapes.html" target="_top">Frames</a></li>
44<li><a href="CharacterEscapes.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:&nbsp;</li>
64<li>Nested&nbsp;|&nbsp;</li>
65<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
66<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
67<li><a href="#method_summary">Method</a></li>
68</ul>
69<ul class="subNavList">
70<li>Detail:&nbsp;</li>
71<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
72<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</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.io</div>
83<h2 title="Class CharacterEscapes" class="title">Class CharacterEscapes</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.io.CharacterEscapes</li>
91</ul>
92</li>
93</ul>
94<div class="description">
95<ul class="blockList">
96<li class="blockList">
97<hr>
98<br>
99<pre>public abstract class <span class="strong">CharacterEscapes</span>
100extends <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>
101<div class="block">Abstract base class that defines interface for customizing character
102 escaping aspects for String values, for formats that use escaping.
103 For JSON this applies to both property names and String values.</div>
104<dl><dt><span class="strong">Since:</span></dt>
105  <dd>1.8</dd></dl>
106</li>
107</ul>
108</div>
109<div class="summary">
110<ul class="blockList">
111<li class="blockList">
112<!-- =========== FIELD SUMMARY =========== -->
113<ul class="blockList">
114<li class="blockList"><a name="field_summary">
115<!--   -->
116</a>
117<h3>Field Summary</h3>
118<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
119<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
120<tr>
121<th class="colFirst" scope="col">Modifier and Type</th>
122<th class="colLast" scope="col">Field and Description</th>
123</tr>
124<tr class="altColor">
125<td class="colFirst"><code>static int</code></td>
126<td class="colLast"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#ESCAPE_CUSTOM">ESCAPE_CUSTOM</a></strong></code>
127<div class="block">Value used for lookup tables to indicate that matching characters
128 will need custom escapes; and that another call
129 to <a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#getEscapeSequence(int)"><code>getEscapeSequence(int)</code></a> is needed to figure out exact escape
130 sequence to output.</div>
131</td>
132</tr>
133<tr class="rowColor">
134<td class="colFirst"><code>static int</code></td>
135<td class="colLast"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#ESCAPE_NONE">ESCAPE_NONE</a></strong></code>
136<div class="block">Value used for lookup tables to indicate that matching characters
137 do not need to be escaped.</div>
138</td>
139</tr>
140<tr class="altColor">
141<td class="colFirst"><code>static int</code></td>
142<td class="colLast"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#ESCAPE_STANDARD">ESCAPE_STANDARD</a></strong></code>
143<div class="block">Value used for lookup tables to indicate that matching characters
144 are to be escaped using standard escaping; for JSON this means
145 (for example) using "backslash - u" escape method.</div>
146</td>
147</tr>
148</table>
149</li>
150</ul>
151<!-- ======== CONSTRUCTOR SUMMARY ======== -->
152<ul class="blockList">
153<li class="blockList"><a name="constructor_summary">
154<!--   -->
155</a>
156<h3>Constructor Summary</h3>
157<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
158<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
159<tr>
160<th class="colOne" scope="col">Constructor and Description</th>
161</tr>
162<tr class="altColor">
163<td class="colOne"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#CharacterEscapes()">CharacterEscapes</a></strong>()</code>&nbsp;</td>
164</tr>
165</table>
166</li>
167</ul>
168<!-- ========== METHOD SUMMARY =========== -->
169<ul class="blockList">
170<li class="blockList"><a name="method_summary">
171<!--   -->
172</a>
173<h3>Method Summary</h3>
174<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
175<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
176<tr>
177<th class="colFirst" scope="col">Modifier and Type</th>
178<th class="colLast" scope="col">Method and Description</th>
179</tr>
180<tr class="altColor">
181<td class="colFirst"><code>abstract int[]</code></td>
182<td class="colLast"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#getEscapeCodesForAscii()">getEscapeCodesForAscii</a></strong>()</code>
183<div class="block">Method generators can call to get lookup table for determining
184 escape handling for first 128 characters of Unicode (ASCII
185 characters.</div>
186</td>
187</tr>
188<tr class="rowColor">
189<td class="colFirst"><code>abstract <a href="../../../../org/codehaus/jackson/SerializableString.html" title="interface in org.codehaus.jackson">SerializableString</a></code></td>
190<td class="colLast"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#getEscapeSequence(int)">getEscapeSequence</a></strong>(int&nbsp;ch)</code>
191<div class="block">Method generators can call to get lookup table for determining
192 exact escape sequence to use for given character.</div>
193</td>
194</tr>
195<tr class="altColor">
196<td class="colFirst"><code>static int[]</code></td>
197<td class="colLast"><code><strong><a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#standardAsciiEscapesForJSON()">standardAsciiEscapesForJSON</a></strong>()</code>
198<div class="block">Helper method that can be used to get a copy of standard JSON
199 escape definitions; this is useful when just wanting to slightly
200 customize definitions.</div>
201</td>
202</tr>
203</table>
204<ul class="blockList">
205<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
206<!--   -->
207</a>
208<h3>Methods inherited from class&nbsp;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>
209<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>
210</ul>
211</li>
212</ul>
213</li>
214</ul>
215</div>
216<div class="details">
217<ul class="blockList">
218<li class="blockList">
219<!-- ============ FIELD DETAIL =========== -->
220<ul class="blockList">
221<li class="blockList"><a name="field_detail">
222<!--   -->
223</a>
224<h3>Field Detail</h3>
225<a name="ESCAPE_NONE">
226<!--   -->
227</a>
228<ul class="blockList">
229<li class="blockList">
230<h4>ESCAPE_NONE</h4>
231<pre>public static final&nbsp;int ESCAPE_NONE</pre>
232<div class="block">Value used for lookup tables to indicate that matching characters
233 do not need to be escaped.</div>
234<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.codehaus.jackson.io.CharacterEscapes.ESCAPE_NONE">Constant Field Values</a></dd></dl>
235</li>
236</ul>
237<a name="ESCAPE_STANDARD">
238<!--   -->
239</a>
240<ul class="blockList">
241<li class="blockList">
242<h4>ESCAPE_STANDARD</h4>
243<pre>public static final&nbsp;int ESCAPE_STANDARD</pre>
244<div class="block">Value used for lookup tables to indicate that matching characters
245 are to be escaped using standard escaping; for JSON this means
246 (for example) using "backslash - u" escape method.</div>
247<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.codehaus.jackson.io.CharacterEscapes.ESCAPE_STANDARD">Constant Field Values</a></dd></dl>
248</li>
249</ul>
250<a name="ESCAPE_CUSTOM">
251<!--   -->
252</a>
253<ul class="blockListLast">
254<li class="blockList">
255<h4>ESCAPE_CUSTOM</h4>
256<pre>public static final&nbsp;int ESCAPE_CUSTOM</pre>
257<div class="block">Value used for lookup tables to indicate that matching characters
258 will need custom escapes; and that another call
259 to <a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#getEscapeSequence(int)"><code>getEscapeSequence(int)</code></a> is needed to figure out exact escape
260 sequence to output.</div>
261<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../constant-values.html#org.codehaus.jackson.io.CharacterEscapes.ESCAPE_CUSTOM">Constant Field Values</a></dd></dl>
262</li>
263</ul>
264</li>
265</ul>
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="CharacterEscapes()">
273<!--   -->
274</a>
275<ul class="blockListLast">
276<li class="blockList">
277<h4>CharacterEscapes</h4>
278<pre>public&nbsp;CharacterEscapes()</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="getEscapeCodesForAscii()">
290<!--   -->
291</a>
292<ul class="blockList">
293<li class="blockList">
294<h4>getEscapeCodesForAscii</h4>
295<pre>public abstract&nbsp;int[]&nbsp;getEscapeCodesForAscii()</pre>
296<div class="block">Method generators can call to get lookup table for determining
297 escape handling for first 128 characters of Unicode (ASCII
298 characters. Caller is not to modify contents of this array, since
299 this is expected to be a shared copy.</div>
300<dl><dt><span class="strong">Returns:</span></dt><dd>Array with size of at least 128, where first 128 entries
301    have either one of <code>ESCAPE_xxx</code> constants, or non-zero positive
302    integer (meaning of which is data format specific; for JSON it means
303    that combination of backslash and character with that value is to be used)
304    to indicate that specific escape sequence is to be used.</dd></dl>
305</li>
306</ul>
307<a name="getEscapeSequence(int)">
308<!--   -->
309</a>
310<ul class="blockList">
311<li class="blockList">
312<h4>getEscapeSequence</h4>
313<pre>public abstract&nbsp;<a href="../../../../org/codehaus/jackson/SerializableString.html" title="interface in org.codehaus.jackson">SerializableString</a>&nbsp;getEscapeSequence(int&nbsp;ch)</pre>
314<div class="block">Method generators can call to get lookup table for determining
315 exact escape sequence to use for given character.
316 It can be called for any character, but typically is called for
317 either for ASCII characters for which custom escape
318 sequence is needed; or for any non-ASCII character.</div>
319</li>
320</ul>
321<a name="standardAsciiEscapesForJSON()">
322<!--   -->
323</a>
324<ul class="blockListLast">
325<li class="blockList">
326<h4>standardAsciiEscapesForJSON</h4>
327<pre>public static&nbsp;int[]&nbsp;standardAsciiEscapesForJSON()</pre>
328<div class="block">Helper method that can be used to get a copy of standard JSON
329 escape definitions; this is useful when just wanting to slightly
330 customize definitions. Caller can modify this array as it sees
331 fit and usually returns modified instance via <a href="../../../../org/codehaus/jackson/io/CharacterEscapes.html#getEscapeCodesForAscii()"><code>getEscapeCodesForAscii()</code></a></div>
332</li>
333</ul>
334</li>
335</ul>
336</li>
337</ul>
338</div>
339</div>
340<!-- ========= END OF CLASS DATA ========= -->
341<!-- ======= START OF BOTTOM NAVBAR ====== -->
342<div class="bottomNav"><a name="navbar_bottom">
343<!--   -->
344</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
345<!--   -->
346</a>
347<ul class="navList" title="Navigation">
348<li><a href="../../../../overview-summary.html">Overview</a></li>
349<li><a href="package-summary.html">Package</a></li>
350<li class="navBarCell1Rev">Class</li>
351<li><a href="class-use/CharacterEscapes.html">Use</a></li>
352<li><a href="package-tree.html">Tree</a></li>
353<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
354<li><a href="../../../../index-all.html">Index</a></li>
355<li><a href="../../../../help-doc.html">Help</a></li>
356</ul>
357</div>
358<div class="subNav">
359<ul class="navList">
360<li>Prev Class</li>
361<li><a href="../../../../org/codehaus/jackson/io/InputDecorator.html" title="class in org.codehaus.jackson.io"><span class="strong">Next Class</span></a></li>
362</ul>
363<ul class="navList">
364<li><a href="../../../../index.html?org/codehaus/jackson/io/CharacterEscapes.html" target="_top">Frames</a></li>
365<li><a href="CharacterEscapes.html" target="_top">No Frames</a></li>
366</ul>
367<ul class="navList" id="allclasses_navbar_bottom">
368<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
369</ul>
370<div>
371<script type="text/javascript"><!--
372  allClassesLink = document.getElementById("allclasses_navbar_bottom");
373  if(window==top) {
374    allClassesLink.style.display = "block";
375  }
376  else {
377    allClassesLink.style.display = "none";
378  }
379  //-->
380</script>
381</div>
382<div>
383<ul class="subNavList">
384<li>Summary:&nbsp;</li>
385<li>Nested&nbsp;|&nbsp;</li>
386<li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
387<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
388<li><a href="#method_summary">Method</a></li>
389</ul>
390<ul class="subNavList">
391<li>Detail:&nbsp;</li>
392<li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
393<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
394<li><a href="#method_detail">Method</a></li>
395</ul>
396</div>
397<a name="skip-navbar_bottom">
398<!--   -->
399</a></div>
400<!-- ======== END OF BOTTOM NAVBAR ======= -->
401</body>
402</html>
403