MCPcopy Index your code
hub / github.com/NASAWorldWind/WorldWindJava / PrettyPrinter

Interface PrettyPrinter

src/org/codehaus/jackson/PrettyPrinter.java:12–189  ·  view source on GitHub ↗

Interface for objects that implement pretty printer functionality, such as indentation. Pretty printers are used to add white space in output JSON content, to make results more human readable. Usually this means things like adding linefeeds and indentation.

Source from the content-addressed store, hash-verified

10 * linefeeds and indentation.
11 */
12public interface PrettyPrinter
13{
14 /*
15 //////////////////////////////////////////////////////
16 // First methods that act both as events, and expect
17 // output for correct functioning (i.e something gets
18 // output even when not pretty-printing)
19 //////////////////////////////////////////////////////
20 */
21
22 // // // Root-level handling:
23
24 /**
25 * Method called after a root-level value has been completely
26 * output, and before another value is to be output.
27 *<p>
28 * Default
29 * handling (without pretty-printing) will output a space, to
30 * allow values to be parsed correctly. Pretty-printer is
31 * to output some other suitable and nice-looking separator
32 * (tab(s), space(s), linefeed(s) or any combination thereof).
33 * @param jg Undocumented.
34 * @throws java.io.IOException Undocumented.
35 * @throws org.codehaus.jackson.JsonGenerationException Undocumented.
36 */
37 public void writeRootValueSeparator(JsonGenerator jg)
38 throws IOException, JsonGenerationException;
39
40 // // Object handling
41
42 /**
43 * Method called when an Object value is to be output, before
44 * any fields are output.
45 *<p>
46 * Default handling (without pretty-printing) will output
47 * the opening curly bracket.
48 * Pretty-printer is
49 * to output a curly bracket as well, but can surround that
50 * with other (white-space) decoration.
51 * @param jg Undocumented.
52 * @throws java.io.IOException Undocumented.
53 * @throws org.codehaus.jackson.JsonGenerationException Undocumented.
54 */
55 public void writeStartObject(JsonGenerator jg)
56 throws IOException, JsonGenerationException;
57
58 /**
59 * Method called after an Object value has been completely output
60 * (minus closing curly bracket).
61 *<p>
62 * Default handling (without pretty-printing) will output
63 * the closing curly bracket.
64 * Pretty-printer is
65 * to output a curly bracket as well, but can surround that
66 * with other (white-space) decoration.
67 *
68 * @param jg Undocumented.
69 * @param nrOfEntries Number of direct members of the array that

Callers 21

writeStartObjectMethod · 0.65
writeStartObjectMethod · 0.65
serializeMethod · 0.65
writeEndObjectMethod · 0.65
closeMethod · 0.65
writeEndObjectMethod · 0.65
serializeMethod · 0.65
_writePPFieldNameMethod · 0.65
writeStartArrayMethod · 0.65
writeStartArrayMethod · 0.65

Implementers 1

DefaultPrettyPrintersrc/org/codehaus/jackson/impl/DefaultP

Calls

no outgoing calls

Tested by

no test coverage detected