Codebase list libgoogle-gson-java / cca80abd-085b-4221-84ca-9da892774205/upstream
Import upstream version 2.8.7 Debian Janitor 2 years ago
131 changed file(s) with 261 addition(s) and 27840 deletion(s). Raw diff Collapse all Expand all
0 version: 2
1 updates:
2 - package-ecosystem: "maven"
3 directory: "/"
4 schedule:
5 interval: "daily"
0 name: "Validate Gradle Wrapper"
1 on: [push, pull_request]
2
3 jobs:
4 validation:
5 name: "Validation"
6 runs-on: ubuntu-latest
7 steps:
8 - uses: actions/checkout@v2
9 - uses: gradle/wrapper-validation-action@v1
1717 build
1818
1919 .DS_Store
20
21 examples/android-proguard-example/gen
00 language: java
11
22 jdk:
3 - oraclejdk9
3 - openjdk11
44
55 install: mvn -f gson install -DskipTests=true
66 script: mvn -f gson test
00 Change Log
11 ==========
2
3 ## Version 2.8.6
4 _2019-10-04_ [GitHub Diff](https://github.com/google/gson/compare/gson-parent-2.8.5...gson-parent-2.8.6)
5 * Added static methods `JsonParser.parseString` and `JsonParser.parseReader` and deprecated instance method `JsonParser.parse`
6 * Java 9 module-info support
27
38 ## Version 2.8.5
49 _2018-05-21_ [GitHub Diff](https://github.com/google/gson/compare/gson-parent-2.8.4...gson-parent-2.8.5)
1616 Gradle:
1717 ```gradle
1818 dependencies {
19 implementation 'com.google.code.gson:gson:2.8.5'
19 implementation 'com.google.code.gson:gson:2.8.6'
2020 }
2121 ```
2222
2525 <dependency>
2626 <groupId>com.google.code.gson</groupId>
2727 <artifactId>gson</artifactId>
28 <version>2.8.5</version>
28 <version>2.8.6</version>
2929 </dependency>
3030 ```
3131
4242 Please use the 'gson' tag on StackOverflow or the [google-gson Google group](https://groups.google.com/group/google-gson) to discuss Gson or to post questions.
4343
4444 ### Related Content Created by Third Parties
45 * [Gson Tutorial](http://www.studytrails.com/java/json/java-google-json-introduction.jsp) by `StudyTrails`
45 * [Gson Tutorial](https://www.studytrails.com/java/json/java-google-json-introduction/) by `StudyTrails`
4646 * [Gson Tutorial Series](https://futurestud.io/tutorials/gson-getting-started-with-java-json-serialization-deserialization) by `Future Studio`
4747 * [Gson API Report](https://abi-laboratory.pro/java/tracker/timeline/gson/)
4848
7373 ## <a name="TOC-Gson-With-Gradle"></a>Using Gson with Gradle/Android
7474 ```
7575 dependencies {
76 implementation 'com.google.code.gson:gson:2.8.5'
76 implementation 'com.google.code.gson:gson:2.8.6'
7777 }
7878 ```
7979 ## <a name="TOC-Gson-With-Maven"></a>Using Gson with Maven
8585 <dependency>
8686 <groupId>com.google.code.gson</groupId>
8787 <artifactId>gson</artifactId>
88 <version>2.8.5</version>
88 <version>2.8.6</version>
8989 <scope>compile</scope>
9090 </dependency>
9191 </dependencies>
300300
301301 ### <a name="TOC-Built-in-Serializers-and-Deserializers"></a>Built-in Serializers and Deserializers
302302
303 Gson has built-in serializers and deserializers for commonly used classes whose default representation may be inappropriate.
304 Here is a list of such classes:
305
306 1. `java.net.URL` to match it with strings like `"https://github.com/google/gson/"`
307 2. `java.net.URI` to match it with strings like `"/google/gson/"`
303 Gson has built-in serializers and deserializers for commonly used classes whose default representation may be inappropriate, for instance
304
305 * `java.net.URL` to match it with strings like `"https://github.com/google/gson/"`
306 * `java.net.URI` to match it with strings like `"/google/gson/"`
307
308 For many more, see the internal class [`TypeAdapters`](https://github.com/google/gson/blob/master/gson/src/main/java/com/google/gson/internal/bind/TypeAdapters.java).
308309
309310 You can also find source code for some commonly used classes such as JodaTime at [this page](https://sites.google.com/site/gson/gson-type-adapters-for-common-classes-1).
310311
3939 <dependency>
4040 <groupId>junit</groupId>
4141 <artifactId>junit</artifactId>
42 <version>3.8.2</version>
42 <version>4.13.1</version>
4343 <scope>test</scope>
4444 </dependency>
4545 </dependencies>
1414
1515 # Prevent proguard from stripping interface information from TypeAdapter, TypeAdapterFactory,
1616 # JsonSerializer, JsonDeserializer instances (so they can be used in @JsonAdapter)
17 -keep class * implements com.google.gson.TypeAdapter
17 -keep class * extends com.google.gson.TypeAdapter
1818 -keep class * implements com.google.gson.TypeAdapterFactory
1919 -keep class * implements com.google.gson.JsonSerializer
2020 -keep class * implements com.google.gson.JsonDeserializer
5050 <dependency>
5151 <groupId>junit</groupId>
5252 <artifactId>junit</artifactId>
53 <version>3.8.2</version>
53 <version>4.13.1</version>
5454 <scope>test</scope>
5555 </dependency>
5656 </dependencies>
119119 * .registerSubtype(Circle.class)
120120 * .registerSubtype(Diamond.class);
121121 * }</pre>
122 *
123 * <h3>Serialization and deserialization</h3>
124 * In order to serialize and deserialize a polymorphic object,
125 * you must specify the base type explicitly.
126 * <pre> {@code
127 * Diamond diamond = new Diamond();
128 * String json = gson.toJson(diamond, Shape.class);
129 * }</pre>
130 * And then:
131 * <pre> {@code
132 * Shape shape = gson.fromJson(json, Shape.class);
133 * }</pre>
122134 */
123135 public final class RuntimeTypeAdapterFactory<T> implements TypeAdapterFactory {
124136 private final Class<?> baseType;
+0
-6
gson/Gson 2.1 notes.txt less more
0 Dropped support for GsonBuilder.registerTypeHierarchyAdapter+InstanceCreator
1
2 Relax registerTypeHierarchyAdapter order
3 Gson 2.0 failed if you registered Manager then Employee would fail
4 Gson 2.1 it isn't a problem
5 com.google.gson.functional.TypeHierarchyAdapterTest#testRegisterSubTypeFirstNotAllowed
+0
-21
gson/assembly-descriptor.xml less more
0 <assembly>
1 <id>release</id>
2 <formats>
3 <format>zip</format>
4 </formats>
5 <fileSets>
6 <fileSet>
7 <includes>
8 <include>README*</include>
9 <include>LICENSE*</include>
10 </includes>
11 </fileSet>
12 <fileSet>
13 <directory>target</directory>
14 <outputDirectory></outputDirectory>
15 <includes>
16 <include>gson-*.jar</include>
17 </includes>
18 </fileSet>
19 </fileSets>
20 </assembly>
22 Bundle-Description: ${project.description}
33 Bundle-Vendor: Google Gson Project
44 Bundle-ContactAddress: ${project.parent.url}
5 Bundle-RequiredExecutionEnvironment: J2SE-1.5, JavaSE-1.6, JavaSE-1.7, JavaSE-1.8
5 Bundle-RequiredExecutionEnvironment: JavaSE-1.6, JavaSE-1.7, JavaSE-1.8
6 Require-Capability: osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=1.6))"
67
78 -removeheaders: Private-Package
89
+0
-98
gson/docs/javadocs/allclasses-frame.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 All Classes (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18 <FONT size="+1" CLASS="FrameHeadingFont">
19 <B>All Classes</B></FONT>
20 <BR>
21
22 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
23 <TR>
24 <TD NOWRAP><FONT CLASS="FrameItemFont"><A HREF="com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson" target="classFrame"><I>ExclusionStrategy</I></A>
25 <BR>
26 <A HREF="com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations" target="classFrame">Expose</A>
27 <BR>
28 <A HREF="com/google/gson/FieldAttributes.html" title="class in com.google.gson" target="classFrame">FieldAttributes</A>
29 <BR>
30 <A HREF="com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson" target="classFrame">FieldNamingPolicy</A>
31 <BR>
32 <A HREF="com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson" target="classFrame"><I>FieldNamingStrategy</I></A>
33 <BR>
34 <A HREF="com/google/gson/Gson.html" title="class in com.google.gson" target="classFrame">Gson</A>
35 <BR>
36 <A HREF="com/google/gson/GsonBuilder.html" title="class in com.google.gson" target="classFrame">GsonBuilder</A>
37 <BR>
38 <A HREF="com/google/gson/InstanceCreator.html" title="interface in com.google.gson" target="classFrame"><I>InstanceCreator</I></A>
39 <BR>
40 <A HREF="com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations" target="classFrame">JsonAdapter</A>
41 <BR>
42 <A HREF="com/google/gson/JsonArray.html" title="class in com.google.gson" target="classFrame">JsonArray</A>
43 <BR>
44 <A HREF="com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson" target="classFrame"><I>JsonDeserializationContext</I></A>
45 <BR>
46 <A HREF="com/google/gson/JsonDeserializer.html" title="interface in com.google.gson" target="classFrame"><I>JsonDeserializer</I></A>
47 <BR>
48 <A HREF="com/google/gson/JsonElement.html" title="class in com.google.gson" target="classFrame">JsonElement</A>
49 <BR>
50 <A HREF="com/google/gson/JsonIOException.html" title="class in com.google.gson" target="classFrame">JsonIOException</A>
51 <BR>
52 <A HREF="com/google/gson/JsonNull.html" title="class in com.google.gson" target="classFrame">JsonNull</A>
53 <BR>
54 <A HREF="com/google/gson/JsonObject.html" title="class in com.google.gson" target="classFrame">JsonObject</A>
55 <BR>
56 <A HREF="com/google/gson/JsonParseException.html" title="class in com.google.gson" target="classFrame">JsonParseException</A>
57 <BR>
58 <A HREF="com/google/gson/JsonParser.html" title="class in com.google.gson" target="classFrame">JsonParser</A>
59 <BR>
60 <A HREF="com/google/gson/JsonPrimitive.html" title="class in com.google.gson" target="classFrame">JsonPrimitive</A>
61 <BR>
62 <A HREF="com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream" target="classFrame">JsonReader</A>
63 <BR>
64 <A HREF="com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson" target="classFrame"><I>JsonSerializationContext</I></A>
65 <BR>
66 <A HREF="com/google/gson/JsonSerializer.html" title="interface in com.google.gson" target="classFrame"><I>JsonSerializer</I></A>
67 <BR>
68 <A HREF="com/google/gson/JsonStreamParser.html" title="class in com.google.gson" target="classFrame">JsonStreamParser</A>
69 <BR>
70 <A HREF="com/google/gson/JsonSyntaxException.html" title="class in com.google.gson" target="classFrame">JsonSyntaxException</A>
71 <BR>
72 <A HREF="com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream" target="classFrame">JsonToken</A>
73 <BR>
74 <A HREF="com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream" target="classFrame">JsonWriter</A>
75 <BR>
76 <A HREF="com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson" target="classFrame">LongSerializationPolicy</A>
77 <BR>
78 <A HREF="com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream" target="classFrame">MalformedJsonException</A>
79 <BR>
80 <A HREF="com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations" target="classFrame">SerializedName</A>
81 <BR>
82 <A HREF="com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations" target="classFrame">Since</A>
83 <BR>
84 <A HREF="com/google/gson/TypeAdapter.html" title="class in com.google.gson" target="classFrame">TypeAdapter</A>
85 <BR>
86 <A HREF="com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson" target="classFrame"><I>TypeAdapterFactory</I></A>
87 <BR>
88 <A HREF="com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect" target="classFrame">TypeToken</A>
89 <BR>
90 <A HREF="com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations" target="classFrame">Until</A>
91 <BR>
92 </FONT></TD>
93 </TR>
94 </TABLE>
95
96 </BODY>
97 </HTML>
+0
-98
gson/docs/javadocs/allclasses-noframe.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 All Classes (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18 <FONT size="+1" CLASS="FrameHeadingFont">
19 <B>All Classes</B></FONT>
20 <BR>
21
22 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
23 <TR>
24 <TD NOWRAP><FONT CLASS="FrameItemFont"><A HREF="com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><I>ExclusionStrategy</I></A>
25 <BR>
26 <A HREF="com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations">Expose</A>
27 <BR>
28 <A HREF="com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
29 <BR>
30 <A HREF="com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>
31 <BR>
32 <A HREF="com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><I>FieldNamingStrategy</I></A>
33 <BR>
34 <A HREF="com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
35 <BR>
36 <A HREF="com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
37 <BR>
38 <A HREF="com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><I>InstanceCreator</I></A>
39 <BR>
40 <A HREF="com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations">JsonAdapter</A>
41 <BR>
42 <A HREF="com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
43 <BR>
44 <A HREF="com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><I>JsonDeserializationContext</I></A>
45 <BR>
46 <A HREF="com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><I>JsonDeserializer</I></A>
47 <BR>
48 <A HREF="com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
49 <BR>
50 <A HREF="com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>
51 <BR>
52 <A HREF="com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A>
53 <BR>
54 <A HREF="com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
55 <BR>
56 <A HREF="com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A>
57 <BR>
58 <A HREF="com/google/gson/JsonParser.html" title="class in com.google.gson">JsonParser</A>
59 <BR>
60 <A HREF="com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
61 <BR>
62 <A HREF="com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
63 <BR>
64 <A HREF="com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><I>JsonSerializationContext</I></A>
65 <BR>
66 <A HREF="com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><I>JsonSerializer</I></A>
67 <BR>
68 <A HREF="com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A>
69 <BR>
70 <A HREF="com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A>
71 <BR>
72 <A HREF="com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>
73 <BR>
74 <A HREF="com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
75 <BR>
76 <A HREF="com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>
77 <BR>
78 <A HREF="com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream">MalformedJsonException</A>
79 <BR>
80 <A HREF="com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations">SerializedName</A>
81 <BR>
82 <A HREF="com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations">Since</A>
83 <BR>
84 <A HREF="com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
85 <BR>
86 <A HREF="com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><I>TypeAdapterFactory</I></A>
87 <BR>
88 <A HREF="com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
89 <BR>
90 <A HREF="com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations">Until</A>
91 <BR>
92 </FONT></TD>
93 </TR>
94 </TABLE>
95
96 </BODY>
97 </HTML>
+0
-305
gson/docs/javadocs/com/google/gson/ExclusionStrategy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 ExclusionStrategy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="ExclusionStrategy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ExclusionStrategy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV CLASS&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/ExclusionStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="ExclusionStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface ExclusionStrategy</H2>
94 <HR>
95 <DL>
96 <DT><PRE>public interface <B>ExclusionStrategy</B></DL>
97 </PRE>
98
99 <P>
100 A strategy (or policy) definition that is used to decide whether or not a field or top-level
101 class should be serialized or deserialized as part of the JSON output/input. For serialization,
102 if the <A HREF="../../../com/google/gson/ExclusionStrategy.html#shouldSkipClass(java.lang.Class)"><CODE>shouldSkipClass(Class)</CODE></A> method returns true then that class or field type
103 will not be part of the JSON output. For deserialization, if <A HREF="../../../com/google/gson/ExclusionStrategy.html#shouldSkipClass(java.lang.Class)"><CODE>shouldSkipClass(Class)</CODE></A>
104 returns true, then it will not be set as part of the Java object structure.
105
106 <p>The following are a few examples that shows how you can use this exclusion mechanism.
107
108 <p><strong>Exclude fields and objects based on a particular class type:</strong>
109 <pre class="code">
110 private static class SpecificClassExclusionStrategy implements ExclusionStrategy {
111 private final Class&lt;?&gt; excludedThisClass;
112
113 public SpecificClassExclusionStrategy(Class&lt;?&gt; excludedThisClass) {
114 this.excludedThisClass = excludedThisClass;
115 }
116
117 public boolean shouldSkipClass(Class&lt;?&gt; clazz) {
118 return excludedThisClass.equals(clazz);
119 }
120
121 public boolean shouldSkipField(FieldAttributes f) {
122 return excludedThisClass.equals(f.getDeclaredClass());
123 }
124 }
125 </pre>
126
127 <p><strong>Excludes fields and objects based on a particular annotation:</strong>
128 <pre class="code">
129 public &#64interface FooAnnotation {
130 // some implementation here
131 }
132
133 // Excludes any field (or class) that is tagged with an "&#64FooAnnotation"
134 private static class FooAnnotationExclusionStrategy implements ExclusionStrategy {
135 public boolean shouldSkipClass(Class&lt;?&gt; clazz) {
136 return clazz.getAnnotation(FooAnnotation.class) != null;
137 }
138
139 public boolean shouldSkipField(FieldAttributes f) {
140 return f.getAnnotation(FooAnnotation.class) != null;
141 }
142 }
143 </pre>
144
145 <p>Now if you want to configure <code>Gson</code> to use a user defined exclusion strategy, then
146 the <code>GsonBuilder</code> is required. The following is an example of how you can use the
147 <code>GsonBuilder</code> to configure Gson to use one of the above sample:
148 <pre class="code">
149 ExclusionStrategy excludeStrings = new UserDefinedExclusionStrategy(String.class);
150 Gson gson = new GsonBuilder()
151 .setExclusionStrategies(excludeStrings)
152 .create();
153 </pre>
154
155 <p>For certain model classes, you may only want to serialize a field, but exclude it for
156 deserialization. To do that, you can write an <code>ExclusionStrategy</code> as per normal;
157 however, you would register it with the
158 <A HREF="../../../com/google/gson/GsonBuilder.html#addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><CODE>GsonBuilder.addDeserializationExclusionStrategy(ExclusionStrategy)</CODE></A> method.
159 For example:
160 <pre class="code">
161 ExclusionStrategy excludeStrings = new UserDefinedExclusionStrategy(String.class);
162 Gson gson = new GsonBuilder()
163 .addDeserializationExclusionStrategy(excludeStrings)
164 .create();
165 </pre>
166 <P>
167
168 <P>
169 <DL>
170 <DT><B>Since:</B></DT>
171 <DD>1.4</DD>
172 <DT><B>Author:</B></DT>
173 <DD>Inderjeet Singh, Joel Leitch</DD>
174 <DT><B>See Also:</B><DD><A HREF="../../../com/google/gson/GsonBuilder.html#setExclusionStrategies(com.google.gson.ExclusionStrategy...)"><CODE>GsonBuilder.setExclusionStrategies(ExclusionStrategy...)</CODE></A>,
175 <A HREF="../../../com/google/gson/GsonBuilder.html#addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><CODE>GsonBuilder.addDeserializationExclusionStrategy(ExclusionStrategy)</CODE></A>,
176 <A HREF="../../../com/google/gson/GsonBuilder.html#addSerializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><CODE>GsonBuilder.addSerializationExclusionStrategy(ExclusionStrategy)</CODE></A></DL>
177 <HR>
178
179 <P>
180
181 <!-- ========== METHOD SUMMARY =========== -->
182
183 <A NAME="method_summary"><!-- --></A>
184 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
185 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
186 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
187 <B>Method Summary</B></FONT></TH>
188 </TR>
189 <TR BGCOLOR="white" CLASS="TableRowColor">
190 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
191 <CODE>&nbsp;boolean</CODE></FONT></TD>
192 <TD><CODE><B><A HREF="../../../com/google/gson/ExclusionStrategy.html#shouldSkipClass(java.lang.Class)">shouldSkipClass</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;clazz)</CODE>
193
194 <BR>
195 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
196 </TR>
197 <TR BGCOLOR="white" CLASS="TableRowColor">
198 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
199 <CODE>&nbsp;boolean</CODE></FONT></TD>
200 <TD><CODE><B><A HREF="../../../com/google/gson/ExclusionStrategy.html#shouldSkipField(com.google.gson.FieldAttributes)">shouldSkipField</A></B>(<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>&nbsp;f)</CODE>
201
202 <BR>
203 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
204 </TR>
205 </TABLE>
206 &nbsp;
207 <P>
208
209 <!-- ============ METHOD DETAIL ========== -->
210
211 <A NAME="method_detail"><!-- --></A>
212 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
213 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
214 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
215 <B>Method Detail</B></FONT></TH>
216 </TR>
217 </TABLE>
218
219 <A NAME="shouldSkipField(com.google.gson.FieldAttributes)"><!-- --></A><H3>
220 shouldSkipField</H3>
221 <PRE>
222 boolean <B>shouldSkipField</B>(<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>&nbsp;f)</PRE>
223 <DL>
224 <DD><DL>
225 <DT><B>Parameters:</B><DD><CODE>f</CODE> - the field object that is under test
226 <DT><B>Returns:</B><DD>true if the field should be ignored; otherwise false</DL>
227 </DD>
228 </DL>
229 <HR>
230
231 <A NAME="shouldSkipClass(java.lang.Class)"><!-- --></A><H3>
232 shouldSkipClass</H3>
233 <PRE>
234 boolean <B>shouldSkipClass</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;clazz)</PRE>
235 <DL>
236 <DD><DL>
237 <DT><B>Parameters:</B><DD><CODE>clazz</CODE> - the class object that is under test
238 <DT><B>Returns:</B><DD>true if the class should be ignored; otherwise false</DL>
239 </DD>
240 </DL>
241 <!-- ========= END OF CLASS DATA ========= -->
242 <HR>
243
244
245 <!-- ======= START OF BOTTOM NAVBAR ====== -->
246 <A NAME="navbar_bottom"><!-- --></A>
247 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
248 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
249 <TR>
250 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
251 <A NAME="navbar_bottom_firstrow"><!-- --></A>
252 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
253 <TR ALIGN="center" VALIGN="top">
254 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
255 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
256 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
257 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/ExclusionStrategy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
258 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
259 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
260 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
261 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
262 </TR>
263 </TABLE>
264 </TD>
265 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
266 </EM>
267 </TD>
268 </TR>
269
270 <TR>
271 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
272 &nbsp;PREV CLASS&nbsp;
273 &nbsp;<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
274 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
275 <A HREF="../../../index.html?com/google/gson/ExclusionStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
276 &nbsp;<A HREF="ExclusionStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
277 &nbsp;<SCRIPT type="text/javascript">
278 <!--
279 if(window==top) {
280 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
281 }
282 //-->
283 </SCRIPT>
284 <NOSCRIPT>
285 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
286 </NOSCRIPT>
287
288
289 </FONT></TD>
290 </TR>
291 <TR>
292 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
293 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
294 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
295 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
296 </TR>
297 </TABLE>
298 <A NAME="skip-navbar_bottom"></A>
299 <!-- ======== END OF BOTTOM NAVBAR ======= -->
300
301 <HR>
302 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
303 </BODY>
304 </HTML>
+0
-446
gson/docs/javadocs/com/google/gson/FieldAttributes.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 FieldAttributes (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="FieldAttributes (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldAttributes.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/FieldAttributes.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="FieldAttributes.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class FieldAttributes</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.FieldAttributes</B>
97 </PRE>
98 <HR>
99 <DL>
100 <DT><PRE>public final class <B>FieldAttributes</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101 </PRE>
102
103 <P>
104 A data object that stores attributes of a field.
105
106 <p>This class is immutable; therefore, it can be safely shared across threads.
107 <P>
108
109 <P>
110 <DL>
111 <DT><B>Since:</B></DT>
112 <DD>1.4</DD>
113 <DT><B>Author:</B></DT>
114 <DD>Inderjeet Singh, Joel Leitch</DD>
115 </DL>
116 <HR>
117
118 <P>
119
120 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
121
122 <A NAME="constructor_summary"><!-- --></A>
123 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
124 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
125 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
126 <B>Constructor Summary</B></FONT></TH>
127 </TR>
128 <TR BGCOLOR="white" CLASS="TableRowColor">
129 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#FieldAttributes(java.lang.reflect.Field)">FieldAttributes</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Field.html?is-external=true" title="class or interface in java.lang.reflect">Field</A>&nbsp;f)</CODE>
130
131 <BR>
132 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a Field Attributes object from the <code>f</code>.</TD>
133 </TR>
134 </TABLE>
135 &nbsp;
136 <!-- ========== METHOD SUMMARY =========== -->
137
138 <A NAME="method_summary"><!-- --></A>
139 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
140 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
141 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
142 <B>Method Summary</B></FONT></TH>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
146 <CODE>
147 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
148 <TR ALIGN="right" VALIGN="">
149 <TD NOWRAP><FONT SIZE="-1">
150 <CODE>&lt;T extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>&gt;
151 <BR>
152 T</CODE></FONT></TD>
153 </TR>
154 </TABLE>
155 </CODE></FONT></TD>
156 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#getAnnotation(java.lang.Class)">getAnnotation</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;annotation)</CODE>
157
158 <BR>
159 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the <code>T</code> annotation object from this field if it exist; otherwise returns
160 <code>null</code>.</TD>
161 </TR>
162 <TR BGCOLOR="white" CLASS="TableRowColor">
163 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
164 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>&gt;</CODE></FONT></TD>
165 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#getAnnotations()">getAnnotations</A></B>()</CODE>
166
167 <BR>
168 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the annotations that are present on this field.</TD>
169 </TR>
170 <TR BGCOLOR="white" CLASS="TableRowColor">
171 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
172 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;</CODE></FONT></TD>
173 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#getDeclaredClass()">getDeclaredClass</A></B>()</CODE>
174
175 <BR>
176 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <code>Class</code> object that was declared for this field.</TD>
177 </TR>
178 <TR BGCOLOR="white" CLASS="TableRowColor">
179 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
180 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A></CODE></FONT></TD>
181 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#getDeclaredType()">getDeclaredType</A></B>()</CODE>
182
183 <BR>
184 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;For example, assume the following class definition:
185 <pre class="code">
186 public class Foo {
187 private String bar;
188 private List&lt;String&gt; red;
189 }
190
191 Type listParmeterizedType = new TypeToken&lt;List&lt;String&gt;&gt;() {}.getType();</TD>
192 </TR>
193 <TR BGCOLOR="white" CLASS="TableRowColor">
194 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
195 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;</CODE></FONT></TD>
196 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#getDeclaringClass()">getDeclaringClass</A></B>()</CODE>
197
198 <BR>
199 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
200 </TR>
201 <TR BGCOLOR="white" CLASS="TableRowColor">
202 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
203 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
204 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#getName()">getName</A></B>()</CODE>
205
206 <BR>
207 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
208 </TR>
209 <TR BGCOLOR="white" CLASS="TableRowColor">
210 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
211 <CODE>&nbsp;boolean</CODE></FONT></TD>
212 <TD><CODE><B><A HREF="../../../com/google/gson/FieldAttributes.html#hasModifier(int)">hasModifier</A></B>(int&nbsp;modifier)</CODE>
213
214 <BR>
215 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns <code>true</code> if the field is defined with the <code>modifier</code>.</TD>
216 </TR>
217 </TABLE>
218 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
219 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
220 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
221 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
222 </TR>
223 <TR BGCOLOR="white" CLASS="TableRowColor">
224 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
225 </TR>
226 </TABLE>
227 &nbsp;
228 <P>
229
230 <!-- ========= CONSTRUCTOR DETAIL ======== -->
231
232 <A NAME="constructor_detail"><!-- --></A>
233 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
234 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
235 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
236 <B>Constructor Detail</B></FONT></TH>
237 </TR>
238 </TABLE>
239
240 <A NAME="FieldAttributes(java.lang.reflect.Field)"><!-- --></A><H3>
241 FieldAttributes</H3>
242 <PRE>
243 public <B>FieldAttributes</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Field.html?is-external=true" title="class or interface in java.lang.reflect">Field</A>&nbsp;f)</PRE>
244 <DL>
245 <DD>Constructs a Field Attributes object from the <code>f</code>.
246 <P>
247 <DL>
248 <DT><B>Parameters:</B><DD><CODE>f</CODE> - the field to pull attributes from</DL>
249 </DL>
250
251 <!-- ============ METHOD DETAIL ========== -->
252
253 <A NAME="method_detail"><!-- --></A>
254 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
255 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
256 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
257 <B>Method Detail</B></FONT></TH>
258 </TR>
259 </TABLE>
260
261 <A NAME="getDeclaringClass()"><!-- --></A><H3>
262 getDeclaringClass</H3>
263 <PRE>
264 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt; <B>getDeclaringClass</B>()</PRE>
265 <DL>
266 <DD><DL>
267
268 <DT><B>Returns:</B><DD>the declaring class that contains this field</DL>
269 </DD>
270 </DL>
271 <HR>
272
273 <A NAME="getName()"><!-- --></A><H3>
274 getName</H3>
275 <PRE>
276 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getName</B>()</PRE>
277 <DL>
278 <DD><DL>
279
280 <DT><B>Returns:</B><DD>the name of the field</DL>
281 </DD>
282 </DL>
283 <HR>
284
285 <A NAME="getDeclaredType()"><!-- --></A><H3>
286 getDeclaredType</H3>
287 <PRE>
288 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A> <B>getDeclaredType</B>()</PRE>
289 <DL>
290 <DD><p>For example, assume the following class definition:
291 <pre class="code">
292 public class Foo {
293 private String bar;
294 private List&lt;String&gt; red;
295 }
296
297 Type listParmeterizedType = new TypeToken&lt;List&lt;String&gt;&gt;() {}.getType();
298 </pre>
299
300 <p>This method would return <code>String.class</code> for the <code>bar</code> field and
301 <code>listParameterizedType</code> for the <code>red</code> field.
302 <P>
303 <DD><DL>
304
305 <DT><B>Returns:</B><DD>the specific type declared for this field</DL>
306 </DD>
307 </DL>
308 <HR>
309
310 <A NAME="getDeclaredClass()"><!-- --></A><H3>
311 getDeclaredClass</H3>
312 <PRE>
313 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt; <B>getDeclaredClass</B>()</PRE>
314 <DL>
315 <DD>Returns the <code>Class</code> object that was declared for this field.
316
317 <p>For example, assume the following class definition:
318 <pre class="code">
319 public class Foo {
320 private String bar;
321 private List&lt;String&gt; red;
322 }
323 </pre>
324
325 <p>This method would return <code>String.class</code> for the <code>bar</code> field and
326 <code>List.class</code> for the <code>red</code> field.
327 <P>
328 <DD><DL>
329
330 <DT><B>Returns:</B><DD>the specific class object that was declared for the field</DL>
331 </DD>
332 </DL>
333 <HR>
334
335 <A NAME="getAnnotation(java.lang.Class)"><!-- --></A><H3>
336 getAnnotation</H3>
337 <PRE>
338 public &lt;T extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>&gt; T <B>getAnnotation</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;annotation)</PRE>
339 <DL>
340 <DD>Return the <code>T</code> annotation object from this field if it exist; otherwise returns
341 <code>null</code>.
342 <P>
343 <DD><DL>
344 <DT><B>Parameters:</B><DD><CODE>annotation</CODE> - the class of the annotation that will be retrieved
345 <DT><B>Returns:</B><DD>the annotation instance if it is bound to the field; otherwise <code>null</code></DL>
346 </DD>
347 </DL>
348 <HR>
349
350 <A NAME="getAnnotations()"><!-- --></A><H3>
351 getAnnotations</H3>
352 <PRE>
353 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util">Collection</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>&gt; <B>getAnnotations</B>()</PRE>
354 <DL>
355 <DD>Return the annotations that are present on this field.
356 <P>
357 <DD><DL>
358
359 <DT><B>Returns:</B><DD>an array of all the annotations set on the field<DT><B>Since:</B></DT>
360 <DD>1.4</DD>
361 </DL>
362 </DD>
363 </DL>
364 <HR>
365
366 <A NAME="hasModifier(int)"><!-- --></A><H3>
367 hasModifier</H3>
368 <PRE>
369 public boolean <B>hasModifier</B>(int&nbsp;modifier)</PRE>
370 <DL>
371 <DD>Returns <code>true</code> if the field is defined with the <code>modifier</code>.
372
373 <p>This method is meant to be called as:
374 <pre class="code">
375 boolean hasPublicModifier = fieldAttribute.hasModifier(java.lang.reflect.Modifier.PUBLIC);
376 </pre>
377 <P>
378 <DD><DL>
379 <DT><B>See Also:</B><DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Modifier.html?is-external=true" title="class or interface in java.lang.reflect"><CODE>Modifier</CODE></A></DL>
380 </DD>
381 </DL>
382 <!-- ========= END OF CLASS DATA ========= -->
383 <HR>
384
385
386 <!-- ======= START OF BOTTOM NAVBAR ====== -->
387 <A NAME="navbar_bottom"><!-- --></A>
388 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
389 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
390 <TR>
391 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
392 <A NAME="navbar_bottom_firstrow"><!-- --></A>
393 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
394 <TR ALIGN="center" VALIGN="top">
395 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
396 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
397 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
398 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldAttributes.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
399 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
400 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
401 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
402 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
403 </TR>
404 </TABLE>
405 </TD>
406 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
407 </EM>
408 </TD>
409 </TR>
410
411 <TR>
412 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
413 &nbsp;<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
414 &nbsp;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
415 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
416 <A HREF="../../../index.html?com/google/gson/FieldAttributes.html" target="_top"><B>FRAMES</B></A> &nbsp;
417 &nbsp;<A HREF="FieldAttributes.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
418 &nbsp;<SCRIPT type="text/javascript">
419 <!--
420 if(window==top) {
421 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
422 }
423 //-->
424 </SCRIPT>
425 <NOSCRIPT>
426 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
427 </NOSCRIPT>
428
429
430 </FONT></TD>
431 </TR>
432 <TR>
433 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
434 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
435 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
436 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
437 </TR>
438 </TABLE>
439 <A NAME="skip-navbar_bottom"></A>
440 <!-- ======== END OF BOTTOM NAVBAR ======= -->
441
442 <HR>
443 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
444 </BODY>
445 </HTML>
+0
-455
gson/docs/javadocs/com/google/gson/FieldNamingPolicy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 FieldNamingPolicy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="FieldNamingPolicy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldNamingPolicy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/FieldNamingPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="FieldNamingPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#enum_constant_summary">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#enum_constant_detail">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Enum FieldNamingPolicy</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">java.lang.Enum</A>&lt;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&gt;
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.FieldNamingPolicy</B>
98 </PRE>
99 <DL>
100 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&gt;</DD>
101 </DL>
102 <HR>
103 <DL>
104 <DT><PRE>public enum <B>FieldNamingPolicy</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</A>&lt;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&gt;<DT>implements <A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A></DL>
105 </PRE>
106
107 <P>
108 An enumeration that defines a few standard naming conventions for JSON field names.
109 This enumeration should be used in conjunction with <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A>
110 to configure a <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance to properly translate Java field
111 names into the desired JSON field names.
112 <P>
113
114 <P>
115 <DL>
116 <DT><B>Author:</B></DT>
117 <DD>Inderjeet Singh, Joel Leitch</DD>
118 </DL>
119 <HR>
120
121 <P>
122 <!-- =========== ENUM CONSTANT SUMMARY =========== -->
123
124 <A NAME="enum_constant_summary"><!-- --></A>
125 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
126 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
127 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
128 <B>Enum Constant Summary</B></FONT></TH>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#IDENTITY">IDENTITY</A></B></CODE>
132
133 <BR>
134 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Using this naming policy with Gson will ensure that the field name is
135 unchanged.</TD>
136 </TR>
137 <TR BGCOLOR="white" CLASS="TableRowColor">
138 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#LOWER_CASE_WITH_DASHES">LOWER_CASE_WITH_DASHES</A></B></CODE>
139
140 <BR>
141 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Using this naming policy with Gson will modify the Java Field name from its camel cased
142 form to a lower case field name where each word is separated by a dash (-).</TD>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#LOWER_CASE_WITH_UNDERSCORES">LOWER_CASE_WITH_UNDERSCORES</A></B></CODE>
146
147 <BR>
148 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Using this naming policy with Gson will modify the Java Field name from its camel cased
149 form to a lower case field name where each word is separated by an underscore (_).</TD>
150 </TR>
151 <TR BGCOLOR="white" CLASS="TableRowColor">
152 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#UPPER_CAMEL_CASE">UPPER_CAMEL_CASE</A></B></CODE>
153
154 <BR>
155 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Using this naming policy with Gson will ensure that the first "letter" of the Java
156 field name is capitalized when serialized to its JSON form.</TD>
157 </TR>
158 <TR BGCOLOR="white" CLASS="TableRowColor">
159 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#UPPER_CAMEL_CASE_WITH_SPACES">UPPER_CAMEL_CASE_WITH_SPACES</A></B></CODE>
160
161 <BR>
162 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Using this naming policy with Gson will ensure that the first "letter" of the Java
163 field name is capitalized when serialized to its JSON form and the words will be
164 separated by a space.</TD>
165 </TR>
166 </TABLE>
167 &nbsp;
168 <!-- ========== METHOD SUMMARY =========== -->
169
170 <A NAME="method_summary"><!-- --></A>
171 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
172 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
173 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
174 <B>Method Summary</B></FONT></TH>
175 </TR>
176 <TR BGCOLOR="white" CLASS="TableRowColor">
177 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
178 <CODE>static&nbsp;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></CODE></FONT></TD>
179 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#valueOf(java.lang.String)">valueOf</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
180
181 <BR>
182 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the enum constant of this type with the specified name.</TD>
183 </TR>
184 <TR BGCOLOR="white" CLASS="TableRowColor">
185 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
186 <CODE>static&nbsp;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>[]</CODE></FONT></TD>
187 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html#values()">values</A></B>()</CODE>
188
189 <BR>
190 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an array containing the constants of this enum type, in
191 the order they are declared.</TD>
192 </TR>
193 </TABLE>
194 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Enum"><!-- --></A>
195 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
196 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
197 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</A></B></TH>
198 </TR>
199 <TR BGCOLOR="white" CLASS="TableRowColor">
200 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Enum.html?is-external=true#valueOf(java.lang.Class, java.lang.String)" title="class or interface in java.lang">valueOf</A></CODE></TD>
201 </TR>
202 </TABLE>
203 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
204 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
205 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
206 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
207 </TR>
208 <TR BGCOLOR="white" CLASS="TableRowColor">
209 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
210 </TR>
211 </TABLE>
212 &nbsp;<A NAME="methods_inherited_from_class_com.google.gson.FieldNamingStrategy"><!-- --></A>
213 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
214 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
215 <TH ALIGN="left"><B>Methods inherited from interface com.google.gson.<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A></B></TH>
216 </TR>
217 <TR BGCOLOR="white" CLASS="TableRowColor">
218 <TD><CODE><A HREF="../../../com/google/gson/FieldNamingStrategy.html#translateName(java.lang.reflect.Field)">translateName</A></CODE></TD>
219 </TR>
220 </TABLE>
221 &nbsp;
222 <P>
223
224 <!-- ============ ENUM CONSTANT DETAIL =========== -->
225
226 <A NAME="enum_constant_detail"><!-- --></A>
227 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
228 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
229 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
230 <B>Enum Constant Detail</B></FONT></TH>
231 </TR>
232 </TABLE>
233
234 <A NAME="IDENTITY"><!-- --></A><H3>
235 IDENTITY</H3>
236 <PRE>
237 public static final <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> <B>IDENTITY</B></PRE>
238 <DL>
239 <DD>Using this naming policy with Gson will ensure that the field name is
240 unchanged.
241 <P>
242 <DL>
243 </DL>
244 </DL>
245 <HR>
246
247 <A NAME="UPPER_CAMEL_CASE"><!-- --></A><H3>
248 UPPER_CAMEL_CASE</H3>
249 <PRE>
250 public static final <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> <B>UPPER_CAMEL_CASE</B></PRE>
251 <DL>
252 <DD>Using this naming policy with Gson will ensure that the first "letter" of the Java
253 field name is capitalized when serialized to its JSON form.
254
255 <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
256 <ul>
257 <li>someFieldName ---> SomeFieldName</li>
258 <li>_someFieldName ---> _SomeFieldName</li>
259 </ul>
260 <P>
261 <DL>
262 </DL>
263 </DL>
264 <HR>
265
266 <A NAME="UPPER_CAMEL_CASE_WITH_SPACES"><!-- --></A><H3>
267 UPPER_CAMEL_CASE_WITH_SPACES</H3>
268 <PRE>
269 public static final <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> <B>UPPER_CAMEL_CASE_WITH_SPACES</B></PRE>
270 <DL>
271 <DD>Using this naming policy with Gson will ensure that the first "letter" of the Java
272 field name is capitalized when serialized to its JSON form and the words will be
273 separated by a space.
274
275 <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
276 <ul>
277 <li>someFieldName ---> Some Field Name</li>
278 <li>_someFieldName ---> _Some Field Name</li>
279 </ul>
280 <P>
281 <DL>
282 <DT><B>Since:</B></DT>
283 <DD>1.4</DD>
284 </DL>
285 </DL>
286 <HR>
287
288 <A NAME="LOWER_CASE_WITH_UNDERSCORES"><!-- --></A><H3>
289 LOWER_CASE_WITH_UNDERSCORES</H3>
290 <PRE>
291 public static final <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> <B>LOWER_CASE_WITH_UNDERSCORES</B></PRE>
292 <DL>
293 <DD>Using this naming policy with Gson will modify the Java Field name from its camel cased
294 form to a lower case field name where each word is separated by an underscore (_).
295
296 <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
297 <ul>
298 <li>someFieldName ---> some_field_name</li>
299 <li>_someFieldName ---> _some_field_name</li>
300 <li>aStringField ---> a_string_field</li>
301 <li>aURL ---> a_u_r_l</li>
302 </ul>
303 <P>
304 <DL>
305 </DL>
306 </DL>
307 <HR>
308
309 <A NAME="LOWER_CASE_WITH_DASHES"><!-- --></A><H3>
310 LOWER_CASE_WITH_DASHES</H3>
311 <PRE>
312 public static final <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> <B>LOWER_CASE_WITH_DASHES</B></PRE>
313 <DL>
314 <DD>Using this naming policy with Gson will modify the Java Field name from its camel cased
315 form to a lower case field name where each word is separated by a dash (-).
316
317 <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
318 <ul>
319 <li>someFieldName ---> some-field-name</li>
320 <li>_someFieldName ---> _some-field-name</li>
321 <li>aStringField ---> a-string-field</li>
322 <li>aURL ---> a-u-r-l</li>
323 </ul>
324 Using dashes in JavaScript is not recommended since dash is also used for a minus sign in
325 expressions. This requires that a field named with dashes is always accessed as a quoted
326 property like <code>myobject['my-field']</code>. Accessing it as an object field
327 <code>myobject.my-field</code> will result in an unintended javascript expression.
328 <P>
329 <DL>
330 <DT><B>Since:</B></DT>
331 <DD>1.4</DD>
332 </DL>
333 </DL>
334
335 <!-- ============ METHOD DETAIL ========== -->
336
337 <A NAME="method_detail"><!-- --></A>
338 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
339 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
340 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
341 <B>Method Detail</B></FONT></TH>
342 </TR>
343 </TABLE>
344
345 <A NAME="values()"><!-- --></A><H3>
346 values</H3>
347 <PRE>
348 public static <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>[] <B>values</B>()</PRE>
349 <DL>
350 <DD>Returns an array containing the constants of this enum type, in
351 the order they are declared. This method may be used to iterate
352 over the constants as follows:
353 <pre>
354 for (FieldNamingPolicy c : FieldNamingPolicy.values())
355 &nbsp; System.out.println(c);
356 </pre>
357 <P>
358 <DD><DL>
359 </DL>
360 </DD>
361 <DD><DL>
362
363 <DT><B>Returns:</B><DD>an array containing the constants of this enum type, in
364 the order they are declared</DL>
365 </DD>
366 </DL>
367 <HR>
368
369 <A NAME="valueOf(java.lang.String)"><!-- --></A><H3>
370 valueOf</H3>
371 <PRE>
372 public static <A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> <B>valueOf</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</PRE>
373 <DL>
374 <DD>Returns the enum constant of this type with the specified name.
375 The string must match <I>exactly</I> an identifier used to declare an
376 enum constant in this type. (Extraneous whitespace characters are
377 not permitted.)
378 <P>
379 <DD><DL>
380 </DL>
381 </DD>
382 <DD><DL>
383 <DT><B>Parameters:</B><DD><CODE>name</CODE> - the name of the enum constant to be returned.
384 <DT><B>Returns:</B><DD>the enum constant with the specified name
385 <DT><B>Throws:</B>
386 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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
387 with the specified name
388 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if the argument is null</DL>
389 </DD>
390 </DL>
391 <!-- ========= END OF CLASS DATA ========= -->
392 <HR>
393
394
395 <!-- ======= START OF BOTTOM NAVBAR ====== -->
396 <A NAME="navbar_bottom"><!-- --></A>
397 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
398 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
399 <TR>
400 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
401 <A NAME="navbar_bottom_firstrow"><!-- --></A>
402 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
403 <TR ALIGN="center" VALIGN="top">
404 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
405 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
406 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
407 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldNamingPolicy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
408 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
409 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
410 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
411 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
412 </TR>
413 </TABLE>
414 </TD>
415 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
416 </EM>
417 </TD>
418 </TR>
419
420 <TR>
421 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
422 &nbsp;<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
423 &nbsp;<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
424 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
425 <A HREF="../../../index.html?com/google/gson/FieldNamingPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
426 &nbsp;<A HREF="FieldNamingPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
427 &nbsp;<SCRIPT type="text/javascript">
428 <!--
429 if(window==top) {
430 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
431 }
432 //-->
433 </SCRIPT>
434 <NOSCRIPT>
435 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
436 </NOSCRIPT>
437
438
439 </FONT></TD>
440 </TR>
441 <TR>
442 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
443 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#enum_constant_summary">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
444 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
445 DETAIL:&nbsp;<A HREF="#enum_constant_detail">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
446 </TR>
447 </TABLE>
448 <A NAME="skip-navbar_bottom"></A>
449 <!-- ======== END OF BOTTOM NAVBAR ======= -->
450
451 <HR>
452 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
453 </BODY>
454 </HTML>
+0
-227
gson/docs/javadocs/com/google/gson/FieldNamingStrategy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 FieldNamingStrategy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="FieldNamingStrategy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldNamingStrategy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/FieldNamingStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="FieldNamingStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface FieldNamingStrategy</H2>
94 <DL>
95 <DT><B>All Known Implementing Classes:</B> <DD><A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></DD>
96 </DL>
97 <HR>
98 <DL>
99 <DT><PRE>public interface <B>FieldNamingStrategy</B></DL>
100 </PRE>
101
102 <P>
103 A mechanism for providing custom field naming in Gson. This allows the client code to translate
104 field names into a particular convention that is not supported as a normal Java field
105 declaration rules. For example, Java does not support "-" characters in a field name.
106 <P>
107
108 <P>
109 <DL>
110 <DT><B>Since:</B></DT>
111 <DD>1.3</DD>
112 <DT><B>Author:</B></DT>
113 <DD>Inderjeet Singh, Joel Leitch</DD>
114 </DL>
115 <HR>
116
117 <P>
118
119 <!-- ========== METHOD SUMMARY =========== -->
120
121 <A NAME="method_summary"><!-- --></A>
122 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
123 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
124 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
125 <B>Method Summary</B></FONT></TH>
126 </TR>
127 <TR BGCOLOR="white" CLASS="TableRowColor">
128 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
129 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
130 <TD><CODE><B><A HREF="../../../com/google/gson/FieldNamingStrategy.html#translateName(java.lang.reflect.Field)">translateName</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Field.html?is-external=true" title="class or interface in java.lang.reflect">Field</A>&nbsp;f)</CODE>
131
132 <BR>
133 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Translates the field name into its JSON field name representation.</TD>
134 </TR>
135 </TABLE>
136 &nbsp;
137 <P>
138
139 <!-- ============ METHOD DETAIL ========== -->
140
141 <A NAME="method_detail"><!-- --></A>
142 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
143 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
144 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
145 <B>Method Detail</B></FONT></TH>
146 </TR>
147 </TABLE>
148
149 <A NAME="translateName(java.lang.reflect.Field)"><!-- --></A><H3>
150 translateName</H3>
151 <PRE>
152 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>translateName</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Field.html?is-external=true" title="class or interface in java.lang.reflect">Field</A>&nbsp;f)</PRE>
153 <DL>
154 <DD>Translates the field name into its JSON field name representation.
155 <P>
156 <DD><DL>
157 <DT><B>Parameters:</B><DD><CODE>f</CODE> - the field object that we are translating
158 <DT><B>Returns:</B><DD>the translated field name.<DT><B>Since:</B></DT>
159 <DD>1.3</DD>
160 </DL>
161 </DD>
162 </DL>
163 <!-- ========= END OF CLASS DATA ========= -->
164 <HR>
165
166
167 <!-- ======= START OF BOTTOM NAVBAR ====== -->
168 <A NAME="navbar_bottom"><!-- --></A>
169 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
170 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
171 <TR>
172 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
173 <A NAME="navbar_bottom_firstrow"><!-- --></A>
174 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
175 <TR ALIGN="center" VALIGN="top">
176 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
177 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
178 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
179 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/FieldNamingStrategy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
180 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
181 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
182 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
183 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
184 </TR>
185 </TABLE>
186 </TD>
187 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
188 </EM>
189 </TD>
190 </TR>
191
192 <TR>
193 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
194 &nbsp;<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
195 &nbsp;<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
196 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
197 <A HREF="../../../index.html?com/google/gson/FieldNamingStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
198 &nbsp;<A HREF="FieldNamingStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
199 &nbsp;<SCRIPT type="text/javascript">
200 <!--
201 if(window==top) {
202 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
203 }
204 //-->
205 </SCRIPT>
206 <NOSCRIPT>
207 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
208 </NOSCRIPT>
209
210
211 </FONT></TD>
212 </TR>
213 <TR>
214 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
215 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
216 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
217 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
218 </TR>
219 </TABLE>
220 <A NAME="skip-navbar_bottom"></A>
221 <!-- ======== END OF BOTTOM NAVBAR ======= -->
222
223 <HR>
224 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
225 </BODY>
226 </HTML>
+0
-1075
gson/docs/javadocs/com/google/gson/Gson.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Gson (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Gson (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Gson.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/Gson.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Gson.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class Gson</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.Gson</B>
97 </PRE>
98 <HR>
99 <DL>
100 <DT><PRE>public final class <B>Gson</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101 </PRE>
102
103 <P>
104 This is the main class for using Gson. Gson is typically used by first constructing a
105 Gson instance and then invoking <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object)"><CODE>toJson(Object)</CODE></A> or <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)"><CODE>fromJson(String, Class)</CODE></A>
106 methods on it.
107
108 <p>You can create a Gson instance by invoking <code>new Gson()</code> if the default configuration
109 is all you need. You can also use <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A> to build a Gson instance with various
110 configuration options such as versioning support, pretty printing, custom
111 <A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><CODE>JsonSerializer</CODE></A>s, <A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><CODE>JsonDeserializer</CODE></A>s, and <A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><CODE>InstanceCreator</CODE></A>s.</p>
112
113 <p>Here is an example of how Gson is used for a simple Class:
114
115 <pre>
116 Gson gson = new Gson(); // Or use new GsonBuilder().create();
117 MyType target = new MyType();
118 String json = gson.toJson(target); // serializes target to Json
119 MyType target2 = gson.fromJson(json, MyType.class); // deserializes json into target2
120 </pre></p>
121
122 <p>If the object that your are serializing/deserializing is a <code>ParameterizedType</code>
123 (i.e. contains at least one type parameter and may be an array) then you must use the
124 <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type)"><CODE>toJson(Object, Type)</CODE></A> or <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.reflect.Type)"><CODE>fromJson(String, Type)</CODE></A> method. Here is an
125 example for serializing and deserialing a <code>ParameterizedType</code>:
126
127 <pre>
128 Type listType = new TypeToken&lt;List&lt;String&gt;&gt;() {}.getType();
129 List&lt;String&gt; target = new LinkedList&lt;String&gt;();
130 target.add("blah");
131
132 Gson gson = new Gson();
133 String json = gson.toJson(target, listType);
134 List&lt;String&gt; target2 = gson.fromJson(json, listType);
135 </pre></p>
136
137 <p>See the <a href="https://sites.google.com/site/gson/gson-user-guide">Gson User Guide</a>
138 for a more complete set of examples.</p>
139 <P>
140
141 <P>
142 <DL>
143 <DT><B>Author:</B></DT>
144 <DD>Inderjeet Singh, Joel Leitch, Jesse Wilson</DD>
145 <DT><B>See Also:</B><DD><A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A></DL>
146 <HR>
147
148 <P>
149
150 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
151
152 <A NAME="constructor_summary"><!-- --></A>
153 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
154 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
155 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
156 <B>Constructor Summary</B></FONT></TH>
157 </TR>
158 <TR BGCOLOR="white" CLASS="TableRowColor">
159 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#Gson()">Gson</A></B>()</CODE>
160
161 <BR>
162 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a Gson object with default configuration.</TD>
163 </TR>
164 </TABLE>
165 &nbsp;
166 <!-- ========== METHOD SUMMARY =========== -->
167
168 <A NAME="method_summary"><!-- --></A>
169 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
170 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
171 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
172 <B>Method Summary</B></FONT></TH>
173 </TR>
174 <TR BGCOLOR="white" CLASS="TableRowColor">
175 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
176 <CODE>
177 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
178 <TR ALIGN="right" VALIGN="">
179 <TD NOWRAP><FONT SIZE="-1">
180 <CODE>&lt;T&gt; T</CODE></FONT></TD>
181 </TR>
182 </TABLE>
183 </CODE></FONT></TD>
184 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.Class)">fromJson</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
185 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
186
187 <BR>
188 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified parse tree into an object of the
189 specified type.</TD>
190 </TR>
191 <TR BGCOLOR="white" CLASS="TableRowColor">
192 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
193 <CODE>
194 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
195 <TR ALIGN="right" VALIGN="">
196 <TD NOWRAP><FONT SIZE="-1">
197 <CODE>&lt;T&gt; T</CODE></FONT></TD>
198 </TR>
199 </TABLE>
200 </CODE></FONT></TD>
201 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
202 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
203
204 <BR>
205 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified parse tree into an object of the
206 specified type.</TD>
207 </TR>
208 <TR BGCOLOR="white" CLASS="TableRowColor">
209 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
210 <CODE>
211 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
212 <TR ALIGN="right" VALIGN="">
213 <TD NOWRAP><FONT SIZE="-1">
214 <CODE>&lt;T&gt; T</CODE></FONT></TD>
215 </TR>
216 </TABLE>
217 </CODE></FONT></TD>
218 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(com.google.gson.stream.JsonReader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;reader,
219 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
220
221 <BR>
222 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads the next JSON value from <code>reader</code> and convert it to an object
223 of type <code>typeOfT</code>.</TD>
224 </TR>
225 <TR BGCOLOR="white" CLASS="TableRowColor">
226 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
227 <CODE>
228 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
229 <TR ALIGN="right" VALIGN="">
230 <TD NOWRAP><FONT SIZE="-1">
231 <CODE>&lt;T&gt; T</CODE></FONT></TD>
232 </TR>
233 </TABLE>
234 </CODE></FONT></TD>
235 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
236 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
237
238 <BR>
239 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified reader into an object of the
240 specified class.</TD>
241 </TR>
242 <TR BGCOLOR="white" CLASS="TableRowColor">
243 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
244 <CODE>
245 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
246 <TR ALIGN="right" VALIGN="">
247 <TD NOWRAP><FONT SIZE="-1">
248 <CODE>&lt;T&gt; T</CODE></FONT></TD>
249 </TR>
250 </TABLE>
251 </CODE></FONT></TD>
252 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
253 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
254
255 <BR>
256 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified reader into an object of the
257 specified type.</TD>
258 </TR>
259 <TR BGCOLOR="white" CLASS="TableRowColor">
260 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
261 <CODE>
262 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
263 <TR ALIGN="right" VALIGN="">
264 <TD NOWRAP><FONT SIZE="-1">
265 <CODE>&lt;T&gt; T</CODE></FONT></TD>
266 </TR>
267 </TABLE>
268 </CODE></FONT></TD>
269 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json,
270 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
271
272 <BR>
273 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the specified Json into an object of the specified class.</TD>
274 </TR>
275 <TR BGCOLOR="white" CLASS="TableRowColor">
276 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
277 <CODE>
278 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
279 <TR ALIGN="right" VALIGN="">
280 <TD NOWRAP><FONT SIZE="-1">
281 <CODE>&lt;T&gt; T</CODE></FONT></TD>
282 </TR>
283 </TABLE>
284 </CODE></FONT></TD>
285 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json,
286 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
287
288 <BR>
289 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the specified Json into an object of the specified type.</TD>
290 </TR>
291 <TR BGCOLOR="white" CLASS="TableRowColor">
292 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
293 <CODE>
294 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
295 <TR ALIGN="right" VALIGN="">
296 <TD NOWRAP><FONT SIZE="-1">
297 <CODE>&lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
298 </TR>
299 </TABLE>
300 </CODE></FONT></TD>
301 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#getAdapter(java.lang.Class)">getAdapter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;type)</CODE>
302
303 <BR>
304 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type adapter for <code></code> type.</TD>
305 </TR>
306 <TR BGCOLOR="white" CLASS="TableRowColor">
307 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
308 <CODE>
309 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
310 <TR ALIGN="right" VALIGN="">
311 <TD NOWRAP><FONT SIZE="-1">
312 <CODE>&lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
313 </TR>
314 </TABLE>
315 </CODE></FONT></TD>
316 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#getAdapter(com.google.gson.reflect.TypeToken)">getAdapter</A></B>(<A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
317
318 <BR>
319 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type adapter for <code></code> type.</TD>
320 </TR>
321 <TR BGCOLOR="white" CLASS="TableRowColor">
322 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
323 <CODE>
324 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
325 <TR ALIGN="right" VALIGN="">
326 <TD NOWRAP><FONT SIZE="-1">
327 <CODE>&lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
328 </TR>
329 </TABLE>
330 </CODE></FONT></TD>
331 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)">getDelegateAdapter</A></B>(<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;skipPast,
332 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
333
334 <BR>
335 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method is used to get an alternate type adapter for the specified type.</TD>
336 </TR>
337 <TR BGCOLOR="white" CLASS="TableRowColor">
338 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
339 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
340 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement)">toJson</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement)</CODE>
341
342 <BR>
343 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s into its equivalent JSON representation.</TD>
344 </TR>
345 <TR BGCOLOR="white" CLASS="TableRowColor">
346 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
347 <CODE>&nbsp;void</CODE></FONT></TD>
348 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, java.lang.Appendable)">toJson</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
349 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
350
351 <BR>
352 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes out the equivalent JSON for a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
353 </TR>
354 <TR BGCOLOR="white" CLASS="TableRowColor">
355 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
356 <CODE>&nbsp;void</CODE></FONT></TD>
357 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
358 <A HREF="../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
359
360 <BR>
361 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON for <code>jsonElement</code> to <code>writer</code>.</TD>
362 </TR>
363 <TR BGCOLOR="white" CLASS="TableRowColor">
364 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
365 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
366 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</CODE>
367
368 <BR>
369 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object into its equivalent Json representation.</TD>
370 </TR>
371 <TR BGCOLOR="white" CLASS="TableRowColor">
372 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
373 <CODE>&nbsp;void</CODE></FONT></TD>
374 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.Appendable)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
375 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
376
377 <BR>
378 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object into its equivalent Json representation.</TD>
379 </TR>
380 <TR BGCOLOR="white" CLASS="TableRowColor">
381 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
382 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
383 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
384 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</CODE>
385
386 <BR>
387 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object, including those of generic types, into its
388 equivalent Json representation.</TD>
389 </TR>
390 <TR BGCOLOR="white" CLASS="TableRowColor">
391 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
392 <CODE>&nbsp;void</CODE></FONT></TD>
393 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, java.lang.Appendable)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
394 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
395 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
396
397 <BR>
398 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object, including those of generic types, into its
399 equivalent Json representation.</TD>
400 </TR>
401 <TR BGCOLOR="white" CLASS="TableRowColor">
402 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
403 <CODE>&nbsp;void</CODE></FONT></TD>
404 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
405 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
406 <A HREF="../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
407
408 <BR>
409 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON representation of <code>src</code> of type <code>typeOfSrc</code> to
410 <code>writer</code>.</TD>
411 </TR>
412 <TR BGCOLOR="white" CLASS="TableRowColor">
413 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
414 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
415 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJsonTree(java.lang.Object)">toJsonTree</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</CODE>
416
417 <BR>
418 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object into its equivalent representation as a tree of
419 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
420 </TR>
421 <TR BGCOLOR="white" CLASS="TableRowColor">
422 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
423 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
424 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toJsonTree(java.lang.Object, java.lang.reflect.Type)">toJsonTree</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
425 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</CODE>
426
427 <BR>
428 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object, including those of generic types, into its
429 equivalent representation as a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
430 </TR>
431 <TR BGCOLOR="white" CLASS="TableRowColor">
432 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
433 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
434 <TD><CODE><B><A HREF="../../../com/google/gson/Gson.html#toString()">toString</A></B>()</CODE>
435
436 <BR>
437 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
438 </TR>
439 </TABLE>
440 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
441 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
442 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
443 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
444 </TR>
445 <TR BGCOLOR="white" CLASS="TableRowColor">
446 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
447 </TR>
448 </TABLE>
449 &nbsp;
450 <P>
451
452 <!-- ========= CONSTRUCTOR DETAIL ======== -->
453
454 <A NAME="constructor_detail"><!-- --></A>
455 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
456 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
457 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
458 <B>Constructor Detail</B></FONT></TH>
459 </TR>
460 </TABLE>
461
462 <A NAME="Gson()"><!-- --></A><H3>
463 Gson</H3>
464 <PRE>
465 public <B>Gson</B>()</PRE>
466 <DL>
467 <DD>Constructs a Gson object with default configuration. The default configuration has the
468 following settings:
469 <ul>
470 <li>The JSON generated by <code>toJson</code> methods is in compact representation. This
471 means that all the unneeded white-space is removed. You can change this behavior with
472 <A HREF="../../../com/google/gson/GsonBuilder.html#setPrettyPrinting()"><CODE>GsonBuilder.setPrettyPrinting()</CODE></A>. </li>
473 <li>The generated JSON omits all the fields that are null. Note that nulls in arrays are
474 kept as is since an array is an ordered list. Moreover, if a field is not null, but its
475 generated JSON is empty, the field is kept. You can configure Gson to serialize null values
476 by setting <A HREF="../../../com/google/gson/GsonBuilder.html#serializeNulls()"><CODE>GsonBuilder.serializeNulls()</CODE></A>.</li>
477 <li>Gson provides default serialization and deserialization for Enums, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util"><CODE>Map</CODE></A>,
478 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/net/URL.html?is-external=true" title="class or interface in java.net"><CODE>URL</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/net/URI.html?is-external=true" title="class or interface in java.net"><CODE>URI</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Locale.html?is-external=true" title="class or interface in java.util"><CODE>Locale</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Date.html?is-external=true" title="class or interface in java.util"><CODE>Date</CODE></A>,
479 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>, and <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A> classes. If you would prefer
480 to change the default representation, you can do so by registering a type adapter through
481 <A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)"><CODE>GsonBuilder.registerTypeAdapter(Type, Object)</CODE></A>. </li>
482 <li>The default Date format is same as <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/text/DateFormat.html?is-external=true#DEFAULT" title="class or interface in java.text"><CODE>DateFormat.DEFAULT</CODE></A>. This format
483 ignores the millisecond portion of the date during serialization. You can change
484 this by invoking <A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(int)"><CODE>GsonBuilder.setDateFormat(int)</CODE></A> or
485 <A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(java.lang.String)"><CODE>GsonBuilder.setDateFormat(String)</CODE></A>. </li>
486 <li>By default, Gson ignores the <A HREF="../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><CODE>Expose</CODE></A> annotation.
487 You can enable Gson to serialize/deserialize only those fields marked with this annotation
488 through <A HREF="../../../com/google/gson/GsonBuilder.html#excludeFieldsWithoutExposeAnnotation()"><CODE>GsonBuilder.excludeFieldsWithoutExposeAnnotation()</CODE></A>. </li>
489 <li>By default, Gson ignores the <A HREF="../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><CODE>Since</CODE></A> annotation. You
490 can enable Gson to use this annotation through <A HREF="../../../com/google/gson/GsonBuilder.html#setVersion(double)"><CODE>GsonBuilder.setVersion(double)</CODE></A>.</li>
491 <li>The default field naming policy for the output Json is same as in Java. So, a Java class
492 field <code>versionNumber</code> will be output as <code>&quot;versionNumber&quot;</code> in
493 Json. The same rules are applied for mapping incoming Json to the Java classes. You can
494 change this policy through <A HREF="../../../com/google/gson/GsonBuilder.html#setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)"><CODE>GsonBuilder.setFieldNamingPolicy(FieldNamingPolicy)</CODE></A>.</li>
495 <li>By default, Gson excludes <code>transient</code> or <code>static</code> fields from
496 consideration for serialization and deserialization. You can change this behavior through
497 <A HREF="../../../com/google/gson/GsonBuilder.html#excludeFieldsWithModifiers(int...)"><CODE>GsonBuilder.excludeFieldsWithModifiers(int...)</CODE></A>.</li>
498 </ul>
499 <P>
500 </DL>
501
502 <!-- ============ METHOD DETAIL ========== -->
503
504 <A NAME="method_detail"><!-- --></A>
505 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
506 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
507 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
508 <B>Method Detail</B></FONT></TH>
509 </TR>
510 </TABLE>
511
512 <A NAME="getAdapter(com.google.gson.reflect.TypeToken)"><!-- --></A><H3>
513 getAdapter</H3>
514 <PRE>
515 public &lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt; <B>getAdapter</B>(<A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</PRE>
516 <DL>
517 <DD>Returns the type adapter for <code></code> type.
518 <P>
519 <DD><DL>
520
521 <DT><B>Throws:</B>
522 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</A></CODE> - if this GSON cannot serialize and
523 deserialize <code>type</code>.</DL>
524 </DD>
525 </DL>
526 <HR>
527
528 <A NAME="getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)"><!-- --></A><H3>
529 getDelegateAdapter</H3>
530 <PRE>
531 public &lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt; <B>getDelegateAdapter</B>(<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;skipPast,
532 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</PRE>
533 <DL>
534 <DD>This method is used to get an alternate type adapter for the specified type. This is used
535 to access a type adapter that is overridden by a <A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><CODE>TypeAdapterFactory</CODE></A> that you
536 may have registered. This features is typically used when you want to register a type
537 adapter that does a little bit of work but then delegates further processing to the Gson
538 default type adapter. Here is an example:
539 <p>Let's say we want to write a type adapter that counts the number of objects being read
540 from or written to JSON. We can achieve this by writing a type adapter factory that uses
541 the <code>getDelegateAdapter</code> method:
542 <pre> <code>class StatsTypeAdapterFactory implements TypeAdapterFactory {
543 public int numReads = 0;
544 public int numWrites = 0;
545 public &amp;lt;T&amp;gt; TypeAdapter&amp;lt;T&amp;gt; create(Gson gson, TypeToken&amp;lt;T&amp;gt; type) {
546 final TypeAdapter&amp;lt;T&amp;gt; delegate = gson.getDelegateAdapter(this, type);
547 return new TypeAdapter&amp;lt;T&amp;gt;() {
548 public void write(JsonWriter out, T value) throws IOException {
549 ++numWrites;
550 delegate.write(out, value);
551 }
552 public T read(JsonReader in) throws IOException {
553 ++numReads;
554 return delegate.read(in);
555 }
556 };
557 }
558 }
559 </code> </pre>
560 This factory can now be used like this:
561 <pre> <code>StatsTypeAdapterFactory stats = new StatsTypeAdapterFactory();
562 Gson gson = new GsonBuilder().registerTypeAdapterFactory(stats).create();
563 // Call gson.toJson() and fromJson methods on objects
564 System.out.println("Num JSON reads" + stats.numReads);
565 System.out.println("Num JSON writes" + stats.numWrites);
566 </code></pre>
567 Note that since you can not override type adapter factories for String and Java primitive
568 types, our stats factory will not count the number of String or primitives that will be
569 read or written.
570 <P>
571 <DD><DL>
572 <DT><B>Parameters:</B><DD><CODE>skipPast</CODE> - The type adapter factory that needs to be skipped while searching for
573 a matching type adapter. In most cases, you should just pass <i>this</i> (the type adapter
574 factory from where <A HREF="../../../com/google/gson/Gson.html#getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)"><CODE>getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken<T>)</CODE></A> method is being invoked).<DD><CODE>type</CODE> - Type for which the delegate adapter is being searched for.<DT><B>Since:</B></DT>
575 <DD>2.2</DD>
576 </DL>
577 </DD>
578 </DL>
579 <HR>
580
581 <A NAME="getAdapter(java.lang.Class)"><!-- --></A><H3>
582 getAdapter</H3>
583 <PRE>
584 public &lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt; <B>getAdapter</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;type)</PRE>
585 <DL>
586 <DD>Returns the type adapter for <code></code> type.
587 <P>
588 <DD><DL>
589
590 <DT><B>Throws:</B>
591 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang">IllegalArgumentException</A></CODE> - if this GSON cannot serialize and
592 deserialize <code>type</code>.</DL>
593 </DD>
594 </DL>
595 <HR>
596
597 <A NAME="toJsonTree(java.lang.Object)"><!-- --></A><H3>
598 toJsonTree</H3>
599 <PRE>
600 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>toJsonTree</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</PRE>
601 <DL>
602 <DD>This method serializes the specified object into its equivalent representation as a tree of
603 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s. This method should be used when the specified object is not a generic
604 type. This method uses <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang"><CODE>Object.getClass()</CODE></A> to get the type for the specified object, but
605 the <code>getClass()</code> loses the generic type information because of the Type Erasure feature
606 of Java. Note that this method works fine if the any of the object fields are of generic type,
607 just the object itself should not be of a generic type. If the object is of generic type, use
608 <A HREF="../../../com/google/gson/Gson.html#toJsonTree(java.lang.Object, java.lang.reflect.Type)"><CODE>toJsonTree(Object, Type)</CODE></A> instead.
609 <P>
610 <DD><DL>
611 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object for which Json representation is to be created setting for Gson
612 <DT><B>Returns:</B><DD>Json representation of <code>src</code>.<DT><B>Since:</B></DT>
613 <DD>1.4</DD>
614 </DL>
615 </DD>
616 </DL>
617 <HR>
618
619 <A NAME="toJsonTree(java.lang.Object, java.lang.reflect.Type)"><!-- --></A><H3>
620 toJsonTree</H3>
621 <PRE>
622 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>toJsonTree</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
623 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</PRE>
624 <DL>
625 <DD>This method serializes the specified object, including those of generic types, into its
626 equivalent representation as a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s. This method must be used if the
627 specified object is a generic type. For non-generic objects, use <A HREF="../../../com/google/gson/Gson.html#toJsonTree(java.lang.Object)"><CODE>toJsonTree(Object)</CODE></A>
628 instead.
629 <P>
630 <DD><DL>
631 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object for which JSON representation is to be created<DD><CODE>typeOfSrc</CODE> - The specific genericized type of src. You can obtain
632 this type by using the <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A> class. For example,
633 to get the type for <code>Collection&lt;Foo&gt;</code>, you should use:
634 <pre>
635 Type typeOfSrc = new TypeToken&lt;Collection&lt;Foo&gt;&gt;(){}.getType();
636 </pre>
637 <DT><B>Returns:</B><DD>Json representation of <code>src</code><DT><B>Since:</B></DT>
638 <DD>1.4</DD>
639 </DL>
640 </DD>
641 </DL>
642 <HR>
643
644 <A NAME="toJson(java.lang.Object)"><!-- --></A><H3>
645 toJson</H3>
646 <PRE>
647 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</PRE>
648 <DL>
649 <DD>This method serializes the specified object into its equivalent Json representation.
650 This method should be used when the specified object is not a generic type. This method uses
651 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang"><CODE>Object.getClass()</CODE></A> to get the type for the specified object, but the
652 <code>getClass()</code> loses the generic type information because of the Type Erasure feature
653 of Java. Note that this method works fine if the any of the object fields are of generic type,
654 just the object itself should not be of a generic type. If the object is of generic type, use
655 <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type)"><CODE>toJson(Object, Type)</CODE></A> instead. If you want to write out the object to a
656 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>, use <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.Appendable)"><CODE>toJson(Object, Appendable)</CODE></A> instead.
657 <P>
658 <DD><DL>
659 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object for which Json representation is to be created setting for Gson
660 <DT><B>Returns:</B><DD>Json representation of <code>src</code>.</DL>
661 </DD>
662 </DL>
663 <HR>
664
665 <A NAME="toJson(java.lang.Object, java.lang.reflect.Type)"><!-- --></A><H3>
666 toJson</H3>
667 <PRE>
668 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
669 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</PRE>
670 <DL>
671 <DD>This method serializes the specified object, including those of generic types, into its
672 equivalent Json representation. This method must be used if the specified object is a generic
673 type. For non-generic objects, use <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object)"><CODE>toJson(Object)</CODE></A> instead. If you want to write out
674 the object to a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang"><CODE>Appendable</CODE></A>, use <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, java.lang.Appendable)"><CODE>toJson(Object, Type, Appendable)</CODE></A> instead.
675 <P>
676 <DD><DL>
677 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object for which JSON representation is to be created<DD><CODE>typeOfSrc</CODE> - The specific genericized type of src. You can obtain
678 this type by using the <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A> class. For example,
679 to get the type for <code>Collection&lt;Foo&gt;</code>, you should use:
680 <pre>
681 Type typeOfSrc = new TypeToken&lt;Collection&lt;Foo&gt;&gt;(){}.getType();
682 </pre>
683 <DT><B>Returns:</B><DD>Json representation of <code>src</code></DL>
684 </DD>
685 </DL>
686 <HR>
687
688 <A NAME="toJson(java.lang.Object, java.lang.Appendable)"><!-- --></A><H3>
689 toJson</H3>
690 <PRE>
691 public void <B>toJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
692 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)
693 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></PRE>
694 <DL>
695 <DD>This method serializes the specified object into its equivalent Json representation.
696 This method should be used when the specified object is not a generic type. This method uses
697 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang"><CODE>Object.getClass()</CODE></A> to get the type for the specified object, but the
698 <code>getClass()</code> loses the generic type information because of the Type Erasure feature
699 of Java. Note that this method works fine if the any of the object fields are of generic type,
700 just the object itself should not be of a generic type. If the object is of generic type, use
701 <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, java.lang.Appendable)"><CODE>toJson(Object, Type, Appendable)</CODE></A> instead.
702 <P>
703 <DD><DL>
704 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object for which Json representation is to be created setting for Gson<DD><CODE>writer</CODE> - Writer to which the Json representation needs to be written
705 <DT><B>Throws:</B>
706 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem writing to the writer<DT><B>Since:</B></DT>
707 <DD>1.2</DD>
708 </DL>
709 </DD>
710 </DL>
711 <HR>
712
713 <A NAME="toJson(java.lang.Object, java.lang.reflect.Type, java.lang.Appendable)"><!-- --></A><H3>
714 toJson</H3>
715 <PRE>
716 public void <B>toJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
717 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
718 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)
719 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></PRE>
720 <DL>
721 <DD>This method serializes the specified object, including those of generic types, into its
722 equivalent Json representation. This method must be used if the specified object is a generic
723 type. For non-generic objects, use <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.Appendable)"><CODE>toJson(Object, Appendable)</CODE></A> instead.
724 <P>
725 <DD><DL>
726 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object for which JSON representation is to be created<DD><CODE>typeOfSrc</CODE> - The specific genericized type of src. You can obtain
727 this type by using the <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A> class. For example,
728 to get the type for <code>Collection&lt;Foo&gt;</code>, you should use:
729 <pre>
730 Type typeOfSrc = new TypeToken&lt;Collection&lt;Foo&gt;&gt;(){}.getType();
731 </pre><DD><CODE>writer</CODE> - Writer to which the Json representation of src needs to be written.
732 <DT><B>Throws:</B>
733 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem writing to the writer<DT><B>Since:</B></DT>
734 <DD>1.2</DD>
735 </DL>
736 </DD>
737 </DL>
738 <HR>
739
740 <A NAME="toJson(java.lang.Object, java.lang.reflect.Type, com.google.gson.stream.JsonWriter)"><!-- --></A><H3>
741 toJson</H3>
742 <PRE>
743 public void <B>toJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
744 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
745 <A HREF="../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)
746 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></PRE>
747 <DL>
748 <DD>Writes the JSON representation of <code>src</code> of type <code>typeOfSrc</code> to
749 <code>writer</code>.
750 <P>
751 <DD><DL>
752
753 <DT><B>Throws:</B>
754 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem writing to the writer</DL>
755 </DD>
756 </DL>
757 <HR>
758
759 <A NAME="toJson(com.google.gson.JsonElement)"><!-- --></A><H3>
760 toJson</H3>
761 <PRE>
762 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toJson</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement)</PRE>
763 <DL>
764 <DD>Converts a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s into its equivalent JSON representation.
765 <P>
766 <DD><DL>
767 <DT><B>Parameters:</B><DD><CODE>jsonElement</CODE> - root of a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s
768 <DT><B>Returns:</B><DD>JSON String representation of the tree<DT><B>Since:</B></DT>
769 <DD>1.4</DD>
770 </DL>
771 </DD>
772 </DL>
773 <HR>
774
775 <A NAME="toJson(com.google.gson.JsonElement, java.lang.Appendable)"><!-- --></A><H3>
776 toJson</H3>
777 <PRE>
778 public void <B>toJson</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
779 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)
780 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></PRE>
781 <DL>
782 <DD>Writes out the equivalent JSON for a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.
783 <P>
784 <DD><DL>
785 <DT><B>Parameters:</B><DD><CODE>jsonElement</CODE> - root of a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s<DD><CODE>writer</CODE> - Writer to which the Json representation needs to be written
786 <DT><B>Throws:</B>
787 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem writing to the writer<DT><B>Since:</B></DT>
788 <DD>1.4</DD>
789 </DL>
790 </DD>
791 </DL>
792 <HR>
793
794 <A NAME="toJson(com.google.gson.JsonElement, com.google.gson.stream.JsonWriter)"><!-- --></A><H3>
795 toJson</H3>
796 <PRE>
797 public void <B>toJson</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
798 <A HREF="../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)
799 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></PRE>
800 <DL>
801 <DD>Writes the JSON for <code>jsonElement</code> to <code>writer</code>.
802 <P>
803 <DD><DL>
804
805 <DT><B>Throws:</B>
806 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem writing to the writer</DL>
807 </DD>
808 </DL>
809 <HR>
810
811 <A NAME="fromJson(java.lang.String, java.lang.Class)"><!-- --></A><H3>
812 fromJson</H3>
813 <PRE>
814 public &lt;T&gt; T <B>fromJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json,
815 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)
816 throws <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
817 <DL>
818 <DD>This method deserializes the specified Json into an object of the specified class. It is not
819 suitable to use if the specified class is a generic type since it will not have the generic
820 type information because of the Type Erasure feature of Java. Therefore, this method should not
821 be used if the desired type is a generic type. Note that this method works fine if the any of
822 the fields of the specified object are generics, just the object itself should not be a
823 generic type. For the cases when the object is of generic type, invoke
824 <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.reflect.Type)"><CODE>fromJson(String, Type)</CODE></A>. If you have the Json in a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A> instead of
825 a String, use <A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)"><CODE>fromJson(Reader, Class)</CODE></A> instead.
826 <P>
827 <DD><DL>
828 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of the desired object<DT><B>Parameters:</B><DD><CODE>json</CODE> - the string from which the object is to be deserialized<DD><CODE>classOfT</CODE> - the class of T
829 <DT><B>Returns:</B><DD>an object of type T from the string. Returns <code>null</code> if <code>json</code> is <code>null</code>.
830 <DT><B>Throws:</B>
831 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type
832 classOfT</DL>
833 </DD>
834 </DL>
835 <HR>
836
837 <A NAME="fromJson(java.lang.String, java.lang.reflect.Type)"><!-- --></A><H3>
838 fromJson</H3>
839 <PRE>
840 public &lt;T&gt; T <B>fromJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json,
841 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)
842 throws <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
843 <DL>
844 <DD>This method deserializes the specified Json into an object of the specified type. This method
845 is useful if the specified object is a generic type. For non-generic objects, use
846 <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)"><CODE>fromJson(String, Class)</CODE></A> instead. If you have the Json in a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A> instead of
847 a String, use <A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.reflect.Type)"><CODE>fromJson(Reader, Type)</CODE></A> instead.
848 <P>
849 <DD><DL>
850 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of the desired object<DT><B>Parameters:</B><DD><CODE>json</CODE> - the string from which the object is to be deserialized<DD><CODE>typeOfT</CODE> - The specific genericized type of src. You can obtain this type by using the
851 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A> class. For example, to get the type for
852 <code>Collection&lt;Foo&gt;</code>, you should use:
853 <pre>
854 Type typeOfT = new TypeToken&lt;Collection&lt;Foo&gt;&gt;(){}.getType();
855 </pre>
856 <DT><B>Returns:</B><DD>an object of type T from the string. Returns <code>null</code> if <code>json</code> is <code>null</code>.
857 <DT><B>Throws:</B>
858 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if json is not a valid representation for an object of type typeOfT
859 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type</DL>
860 </DD>
861 </DL>
862 <HR>
863
864 <A NAME="fromJson(java.io.Reader, java.lang.Class)"><!-- --></A><H3>
865 fromJson</H3>
866 <PRE>
867 public &lt;T&gt; T <B>fromJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
868 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)
869 throws <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A>,
870 <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></PRE>
871 <DL>
872 <DD>This method deserializes the Json read from the specified reader into an object of the
873 specified class. It is not suitable to use if the specified class is a generic type since it
874 will not have the generic type information because of the Type Erasure feature of Java.
875 Therefore, this method should not be used if the desired type is a generic type. Note that
876 this method works fine if the any of the fields of the specified object are generics, just the
877 object itself should not be a generic type. For the cases when the object is of generic type,
878 invoke <A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.reflect.Type)"><CODE>fromJson(Reader, Type)</CODE></A>. If you have the Json in a String form instead of a
879 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A>, use <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)"><CODE>fromJson(String, Class)</CODE></A> instead.
880 <P>
881 <DD><DL>
882 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of the desired object<DT><B>Parameters:</B><DD><CODE>json</CODE> - the reader producing the Json from which the object is to be deserialized.<DD><CODE>classOfT</CODE> - the class of T
883 <DT><B>Returns:</B><DD>an object of type T from the string. Returns <code>null</code> if <code>json</code> is at EOF.
884 <DT><B>Throws:</B>
885 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem reading from the Reader
886 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type<DT><B>Since:</B></DT>
887 <DD>1.2</DD>
888 </DL>
889 </DD>
890 </DL>
891 <HR>
892
893 <A NAME="fromJson(java.io.Reader, java.lang.reflect.Type)"><!-- --></A><H3>
894 fromJson</H3>
895 <PRE>
896 public &lt;T&gt; T <B>fromJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
897 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)
898 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>,
899 <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
900 <DL>
901 <DD>This method deserializes the Json read from the specified reader into an object of the
902 specified type. This method is useful if the specified object is a generic type. For
903 non-generic objects, use <A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)"><CODE>fromJson(Reader, Class)</CODE></A> instead. If you have the Json in a
904 String form instead of a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A>, use <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.reflect.Type)"><CODE>fromJson(String, Type)</CODE></A> instead.
905 <P>
906 <DD><DL>
907 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of the desired object<DT><B>Parameters:</B><DD><CODE>json</CODE> - the reader producing Json from which the object is to be deserialized<DD><CODE>typeOfT</CODE> - The specific genericized type of src. You can obtain this type by using the
908 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A> class. For example, to get the type for
909 <code>Collection&lt;Foo&gt;</code>, you should use:
910 <pre>
911 Type typeOfT = new TypeToken&lt;Collection&lt;Foo&gt;&gt;(){}.getType();
912 </pre>
913 <DT><B>Returns:</B><DD>an object of type T from the json. Returns <code>null</code> if <code>json</code> is at EOF.
914 <DT><B>Throws:</B>
915 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem reading from the Reader
916 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type<DT><B>Since:</B></DT>
917 <DD>1.2</DD>
918 </DL>
919 </DD>
920 </DL>
921 <HR>
922
923 <A NAME="fromJson(com.google.gson.stream.JsonReader, java.lang.reflect.Type)"><!-- --></A><H3>
924 fromJson</H3>
925 <PRE>
926 public &lt;T&gt; T <B>fromJson</B>(<A HREF="../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;reader,
927 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)
928 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>,
929 <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
930 <DL>
931 <DD>Reads the next JSON value from <code>reader</code> and convert it to an object
932 of type <code>typeOfT</code>. Returns <code>null</code>, if the <code>reader</code> is at EOF.
933 Since Type is not parameterized by T, this method is type unsafe and should be used carefully
934 <P>
935 <DD><DL>
936
937 <DT><B>Throws:</B>
938 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE> - if there was a problem writing to the Reader
939 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type</DL>
940 </DD>
941 </DL>
942 <HR>
943
944 <A NAME="fromJson(com.google.gson.JsonElement, java.lang.Class)"><!-- --></A><H3>
945 fromJson</H3>
946 <PRE>
947 public &lt;T&gt; T <B>fromJson</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
948 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)
949 throws <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
950 <DL>
951 <DD>This method deserializes the Json read from the specified parse tree into an object of the
952 specified type. It is not suitable to use if the specified class is a generic type since it
953 will not have the generic type information because of the Type Erasure feature of Java.
954 Therefore, this method should not be used if the desired type is a generic type. Note that
955 this method works fine if the any of the fields of the specified object are generics, just the
956 object itself should not be a generic type. For the cases when the object is of generic type,
957 invoke <A HREF="../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.reflect.Type)"><CODE>fromJson(JsonElement, Type)</CODE></A>.
958 <P>
959 <DD><DL>
960 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of the desired object<DT><B>Parameters:</B><DD><CODE>json</CODE> - the root of the parse tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s from which the object is to
961 be deserialized<DD><CODE>classOfT</CODE> - The class of T
962 <DT><B>Returns:</B><DD>an object of type T from the json. Returns <code>null</code> if <code>json</code> is <code>null</code>.
963 <DT><B>Throws:</B>
964 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type typeOfT<DT><B>Since:</B></DT>
965 <DD>1.3</DD>
966 </DL>
967 </DD>
968 </DL>
969 <HR>
970
971 <A NAME="fromJson(com.google.gson.JsonElement, java.lang.reflect.Type)"><!-- --></A><H3>
972 fromJson</H3>
973 <PRE>
974 public &lt;T&gt; T <B>fromJson</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
975 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)
976 throws <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
977 <DL>
978 <DD>This method deserializes the Json read from the specified parse tree into an object of the
979 specified type. This method is useful if the specified object is a generic type. For
980 non-generic objects, use <A HREF="../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.Class)"><CODE>fromJson(JsonElement, Class)</CODE></A> instead.
981 <P>
982 <DD><DL>
983 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of the desired object<DT><B>Parameters:</B><DD><CODE>json</CODE> - the root of the parse tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s from which the object is to
984 be deserialized<DD><CODE>typeOfT</CODE> - The specific genericized type of src. You can obtain this type by using the
985 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><CODE>TypeToken</CODE></A> class. For example, to get the type for
986 <code>Collection&lt;Foo&gt;</code>, you should use:
987 <pre>
988 Type typeOfT = new TypeToken&lt;Collection&lt;Foo&gt;&gt;(){}.getType();
989 </pre>
990 <DT><B>Returns:</B><DD>an object of type T from the json. Returns <code>null</code> if <code>json</code> is <code>null</code>.
991 <DT><B>Throws:</B>
992 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE> - if json is not a valid representation for an object of type typeOfT<DT><B>Since:</B></DT>
993 <DD>1.3</DD>
994 </DL>
995 </DD>
996 </DL>
997 <HR>
998
999 <A NAME="toString()"><!-- --></A><H3>
1000 toString</H3>
1001 <PRE>
1002 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toString</B>()</PRE>
1003 <DL>
1004 <DD><DL>
1005 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
1006 </DD>
1007 <DD><DL>
1008 </DL>
1009 </DD>
1010 </DL>
1011 <!-- ========= END OF CLASS DATA ========= -->
1012 <HR>
1013
1014
1015 <!-- ======= START OF BOTTOM NAVBAR ====== -->
1016 <A NAME="navbar_bottom"><!-- --></A>
1017 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
1018 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
1019 <TR>
1020 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
1021 <A NAME="navbar_bottom_firstrow"><!-- --></A>
1022 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
1023 <TR ALIGN="center" VALIGN="top">
1024 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
1025 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
1026 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
1027 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Gson.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
1028 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
1029 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
1030 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
1031 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
1032 </TR>
1033 </TABLE>
1034 </TD>
1035 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
1036 </EM>
1037 </TD>
1038 </TR>
1039
1040 <TR>
1041 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
1042 &nbsp;<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
1043 &nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
1044 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
1045 <A HREF="../../../index.html?com/google/gson/Gson.html" target="_top"><B>FRAMES</B></A> &nbsp;
1046 &nbsp;<A HREF="Gson.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
1047 &nbsp;<SCRIPT type="text/javascript">
1048 <!--
1049 if(window==top) {
1050 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
1051 }
1052 //-->
1053 </SCRIPT>
1054 <NOSCRIPT>
1055 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
1056 </NOSCRIPT>
1057
1058
1059 </FONT></TD>
1060 </TR>
1061 <TR>
1062 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
1063 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
1064 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
1065 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
1066 </TR>
1067 </TABLE>
1068 <A NAME="skip-navbar_bottom"></A>
1069 <!-- ======== END OF BOTTOM NAVBAR ======= -->
1070
1071 <HR>
1072 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
1073 </BODY>
1074 </HTML>
+0
-975
gson/docs/javadocs/com/google/gson/GsonBuilder.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 GsonBuilder (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="GsonBuilder (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/GsonBuilder.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/GsonBuilder.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="GsonBuilder.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class GsonBuilder</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.GsonBuilder</B>
97 </PRE>
98 <HR>
99 <DL>
100 <DT><PRE>public final class <B>GsonBuilder</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101 </PRE>
102
103 <P>
104 <p>Use this builder to construct a <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance when you need to set configuration
105 options other than the default. For <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> with default configuration, it is simpler to
106 use <code>new Gson()</code>. <code>GsonBuilder</code> is best used by creating it, and then invoking its
107 various configuration methods, and finally calling create.</p>
108
109 <p>The following is an example shows how to use the <code>GsonBuilder</code> to construct a Gson
110 instance:
111
112 <pre>
113 Gson gson = new GsonBuilder()
114 .registerTypeAdapter(Id.class, new IdTypeAdapter())
115 .enableComplexMapKeySerialization()
116 .serializeNulls()
117 .setDateFormat(DateFormat.LONG)
118 .setFieldNamingPolicy(FieldNamingPolicy.UPPER_CAMEL_CASE)
119 .setPrettyPrinting()
120 .setVersion(1.0)
121 .create();
122 </pre></p>
123
124 <p>NOTES:
125 <ul>
126 <li> the order of invocation of configuration methods does not matter.</li>
127 <li> The default serialization of <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Date.html?is-external=true" title="class or interface in java.util"><CODE>Date</CODE></A> and its subclasses in Gson does
128 not contain time-zone information. So, if you are using date/time instances,
129 use <code>GsonBuilder</code> and its <code>setDateFormat</code> methods.</li>
130 </ul>
131 </p>
132 <P>
133
134 <P>
135 <DL>
136 <DT><B>Author:</B></DT>
137 <DD>Inderjeet Singh, Joel Leitch, Jesse Wilson</DD>
138 </DL>
139 <HR>
140
141 <P>
142
143 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
144
145 <A NAME="constructor_summary"><!-- --></A>
146 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
147 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
148 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
149 <B>Constructor Summary</B></FONT></TH>
150 </TR>
151 <TR BGCOLOR="white" CLASS="TableRowColor">
152 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#GsonBuilder()">GsonBuilder</A></B>()</CODE>
153
154 <BR>
155 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a GsonBuilder instance that can be used to build Gson with various configuration
156 settings.</TD>
157 </TR>
158 </TABLE>
159 &nbsp;
160 <!-- ========== METHOD SUMMARY =========== -->
161
162 <A NAME="method_summary"><!-- --></A>
163 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
164 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
165 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
166 <B>Method Summary</B></FONT></TH>
167 </TR>
168 <TR BGCOLOR="white" CLASS="TableRowColor">
169 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
170 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
171 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)">addDeserializationExclusionStrategy</A></B>(<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</CODE>
172
173 <BR>
174 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply the passed in exclusion strategy during deserialization.</TD>
175 </TR>
176 <TR BGCOLOR="white" CLASS="TableRowColor">
177 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
178 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
179 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#addSerializationExclusionStrategy(com.google.gson.ExclusionStrategy)">addSerializationExclusionStrategy</A></B>(<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</CODE>
180
181 <BR>
182 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply the passed in exclusion strategy during serialization.</TD>
183 </TR>
184 <TR BGCOLOR="white" CLASS="TableRowColor">
185 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
186 <CODE>&nbsp;<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A></CODE></FONT></TD>
187 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#create()">create</A></B>()</CODE>
188
189 <BR>
190 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance based on the current configuration.</TD>
191 </TR>
192 <TR BGCOLOR="white" CLASS="TableRowColor">
193 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
194 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
195 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#disableHtmlEscaping()">disableHtmlEscaping</A></B>()</CODE>
196
197 <BR>
198 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;By default, Gson escapes HTML characters such as &lt; &gt; etc.</TD>
199 </TR>
200 <TR BGCOLOR="white" CLASS="TableRowColor">
201 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
202 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
203 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#disableInnerClassSerialization()">disableInnerClassSerialization</A></B>()</CODE>
204
205 <BR>
206 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to exclude inner classes during serialization.</TD>
207 </TR>
208 <TR BGCOLOR="white" CLASS="TableRowColor">
209 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
210 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
211 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#enableComplexMapKeySerialization()">enableComplexMapKeySerialization</A></B>()</CODE>
212
213 <BR>
214 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Enabling this feature will only change the serialized form if the map key is
215 a complex type (i.e.</TD>
216 </TR>
217 <TR BGCOLOR="white" CLASS="TableRowColor">
218 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
219 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
220 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#excludeFieldsWithModifiers(int...)">excludeFieldsWithModifiers</A></B>(int...&nbsp;modifiers)</CODE>
221
222 <BR>
223 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to excludes all class fields that have the specified modifiers.</TD>
224 </TR>
225 <TR BGCOLOR="white" CLASS="TableRowColor">
226 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
227 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
228 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#excludeFieldsWithoutExposeAnnotation()">excludeFieldsWithoutExposeAnnotation</A></B>()</CODE>
229
230 <BR>
231 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to exclude all fields from consideration for serialization or deserialization
232 that do not have the <A HREF="../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><CODE>Expose</CODE></A> annotation.</TD>
233 </TR>
234 <TR BGCOLOR="white" CLASS="TableRowColor">
235 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
236 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
237 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#generateNonExecutableJson()">generateNonExecutableJson</A></B>()</CODE>
238
239 <BR>
240 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Makes the output JSON non-executable in Javascript by prefixing the generated JSON with some
241 special text.</TD>
242 </TR>
243 <TR BGCOLOR="white" CLASS="TableRowColor">
244 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
245 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
246 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)">registerTypeAdapter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type,
247 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;typeAdapter)</CODE>
248
249 <BR>
250 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson for custom serialization or deserialization.</TD>
251 </TR>
252 <TR BGCOLOR="white" CLASS="TableRowColor">
253 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
254 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
255 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeAdapterFactory(com.google.gson.TypeAdapterFactory)">registerTypeAdapterFactory</A></B>(<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;factory)</CODE>
256
257 <BR>
258 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Register a factory for type adapters.</TD>
259 </TR>
260 <TR BGCOLOR="white" CLASS="TableRowColor">
261 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
262 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
263 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeHierarchyAdapter(java.lang.Class, java.lang.Object)">registerTypeHierarchyAdapter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;baseType,
264 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;typeAdapter)</CODE>
265
266 <BR>
267 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson for custom serialization or deserialization for an inheritance type hierarchy.</TD>
268 </TR>
269 <TR BGCOLOR="white" CLASS="TableRowColor">
270 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
271 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
272 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#serializeNulls()">serializeNulls</A></B>()</CODE>
273
274 <BR>
275 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configure Gson to serialize null fields.</TD>
276 </TR>
277 <TR BGCOLOR="white" CLASS="TableRowColor">
278 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
279 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
280 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#serializeSpecialFloatingPointValues()">serializeSpecialFloatingPointValues</A></B>()</CODE>
281
282 <BR>
283 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Section 2.4 of <a href="http://www.ietf.org/rfc/rfc4627.txt">JSON specification</a> disallows
284 special double values (NaN, Infinity, -Infinity).</TD>
285 </TR>
286 <TR BGCOLOR="white" CLASS="TableRowColor">
287 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
288 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
289 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(int)">setDateFormat</A></B>(int&nbsp;style)</CODE>
290
291 <BR>
292 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to to serialize <code>Date</code> objects according to the style value provided.</TD>
293 </TR>
294 <TR BGCOLOR="white" CLASS="TableRowColor">
295 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
296 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
297 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(int, int)">setDateFormat</A></B>(int&nbsp;dateStyle,
298 int&nbsp;timeStyle)</CODE>
299
300 <BR>
301 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to to serialize <code>Date</code> objects according to the style value provided.</TD>
302 </TR>
303 <TR BGCOLOR="white" CLASS="TableRowColor">
304 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
305 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
306 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(java.lang.String)">setDateFormat</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;pattern)</CODE>
307
308 <BR>
309 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to serialize <code>Date</code> objects according to the pattern provided.</TD>
310 </TR>
311 <TR BGCOLOR="white" CLASS="TableRowColor">
312 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
313 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
314 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setExclusionStrategies(com.google.gson.ExclusionStrategy...)">setExclusionStrategies</A></B>(<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>...&nbsp;strategies)</CODE>
315
316 <BR>
317 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a set of exclusion strategies during both serialization and
318 deserialization.</TD>
319 </TR>
320 <TR BGCOLOR="white" CLASS="TableRowColor">
321 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
322 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
323 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)">setFieldNamingPolicy</A></B>(<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&nbsp;namingConvention)</CODE>
324
325 <BR>
326 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific naming policy to an object's field during serialization
327 and deserialization.</TD>
328 </TR>
329 <TR BGCOLOR="white" CLASS="TableRowColor">
330 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
331 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
332 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setFieldNamingStrategy(com.google.gson.FieldNamingStrategy)">setFieldNamingStrategy</A></B>(<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>&nbsp;fieldNamingStrategy)</CODE>
333
334 <BR>
335 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific naming policy strategy to an object's field during
336 serialization and deserialization.</TD>
337 </TR>
338 <TR BGCOLOR="white" CLASS="TableRowColor">
339 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
340 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
341 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setLongSerializationPolicy(com.google.gson.LongSerializationPolicy)">setLongSerializationPolicy</A></B>(<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&nbsp;serializationPolicy)</CODE>
342
343 <BR>
344 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific serialization policy for <code>Long</code> and <code>long</code>
345 objects.</TD>
346 </TR>
347 <TR BGCOLOR="white" CLASS="TableRowColor">
348 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
349 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
350 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setPrettyPrinting()">setPrettyPrinting</A></B>()</CODE>
351
352 <BR>
353 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to output Json that fits in a page for pretty printing.</TD>
354 </TR>
355 <TR BGCOLOR="white" CLASS="TableRowColor">
356 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
357 <CODE>&nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
358 <TD><CODE><B><A HREF="../../../com/google/gson/GsonBuilder.html#setVersion(double)">setVersion</A></B>(double&nbsp;ignoreVersionsAfter)</CODE>
359
360 <BR>
361 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to enable versioning support.</TD>
362 </TR>
363 </TABLE>
364 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
365 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
366 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
367 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
368 </TR>
369 <TR BGCOLOR="white" CLASS="TableRowColor">
370 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
371 </TR>
372 </TABLE>
373 &nbsp;
374 <P>
375
376 <!-- ========= CONSTRUCTOR DETAIL ======== -->
377
378 <A NAME="constructor_detail"><!-- --></A>
379 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
380 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
381 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
382 <B>Constructor Detail</B></FONT></TH>
383 </TR>
384 </TABLE>
385
386 <A NAME="GsonBuilder()"><!-- --></A><H3>
387 GsonBuilder</H3>
388 <PRE>
389 public <B>GsonBuilder</B>()</PRE>
390 <DL>
391 <DD>Creates a GsonBuilder instance that can be used to build Gson with various configuration
392 settings. GsonBuilder follows the builder pattern, and it is typically used by first
393 invoking various configuration methods to set desired options, and finally calling
394 <A HREF="../../../com/google/gson/GsonBuilder.html#create()"><CODE>create()</CODE></A>.
395 <P>
396 </DL>
397
398 <!-- ============ METHOD DETAIL ========== -->
399
400 <A NAME="method_detail"><!-- --></A>
401 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
402 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
403 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
404 <B>Method Detail</B></FONT></TH>
405 </TR>
406 </TABLE>
407
408 <A NAME="setVersion(double)"><!-- --></A><H3>
409 setVersion</H3>
410 <PRE>
411 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setVersion</B>(double&nbsp;ignoreVersionsAfter)</PRE>
412 <DL>
413 <DD>Configures Gson to enable versioning support.
414 <P>
415 <DD><DL>
416 <DT><B>Parameters:</B><DD><CODE>ignoreVersionsAfter</CODE> - any field or type marked with a version higher than this value
417 are ignored during serialization or deserialization.
418 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern</DL>
419 </DD>
420 </DL>
421 <HR>
422
423 <A NAME="excludeFieldsWithModifiers(int...)"><!-- --></A><H3>
424 excludeFieldsWithModifiers</H3>
425 <PRE>
426 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>excludeFieldsWithModifiers</B>(int...&nbsp;modifiers)</PRE>
427 <DL>
428 <DD>Configures Gson to excludes all class fields that have the specified modifiers. By default,
429 Gson will exclude all fields marked transient or static. This method will override that
430 behavior.
431 <P>
432 <DD><DL>
433 <DT><B>Parameters:</B><DD><CODE>modifiers</CODE> - the field modifiers. You must use the modifiers specified in the
434 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Modifier.html?is-external=true" title="class or interface in java.lang.reflect"><CODE>Modifier</CODE></A> class. For example,
435 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Modifier.html?is-external=true#TRANSIENT" title="class or interface in java.lang.reflect"><CODE>Modifier.TRANSIENT</CODE></A>,
436 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Modifier.html?is-external=true#STATIC" title="class or interface in java.lang.reflect"><CODE>Modifier.STATIC</CODE></A>.
437 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern</DL>
438 </DD>
439 </DL>
440 <HR>
441
442 <A NAME="generateNonExecutableJson()"><!-- --></A><H3>
443 generateNonExecutableJson</H3>
444 <PRE>
445 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>generateNonExecutableJson</B>()</PRE>
446 <DL>
447 <DD>Makes the output JSON non-executable in Javascript by prefixing the generated JSON with some
448 special text. This prevents attacks from third-party sites through script sourcing. See
449 <a href="http://code.google.com/p/google-gson/issues/detail?id=42">Gson Issue 42</a>
450 for details.
451 <P>
452 <DD><DL>
453
454 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
455 <DD>1.3</DD>
456 </DL>
457 </DD>
458 </DL>
459 <HR>
460
461 <A NAME="excludeFieldsWithoutExposeAnnotation()"><!-- --></A><H3>
462 excludeFieldsWithoutExposeAnnotation</H3>
463 <PRE>
464 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>excludeFieldsWithoutExposeAnnotation</B>()</PRE>
465 <DL>
466 <DD>Configures Gson to exclude all fields from consideration for serialization or deserialization
467 that do not have the <A HREF="../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><CODE>Expose</CODE></A> annotation.
468 <P>
469 <DD><DL>
470
471 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern</DL>
472 </DD>
473 </DL>
474 <HR>
475
476 <A NAME="serializeNulls()"><!-- --></A><H3>
477 serializeNulls</H3>
478 <PRE>
479 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>serializeNulls</B>()</PRE>
480 <DL>
481 <DD>Configure Gson to serialize null fields. By default, Gson omits all fields that are null
482 during serialization.
483 <P>
484 <DD><DL>
485
486 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
487 <DD>1.2</DD>
488 </DL>
489 </DD>
490 </DL>
491 <HR>
492
493 <A NAME="enableComplexMapKeySerialization()"><!-- --></A><H3>
494 enableComplexMapKeySerialization</H3>
495 <PRE>
496 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>enableComplexMapKeySerialization</B>()</PRE>
497 <DL>
498 <DD>Enabling this feature will only change the serialized form if the map key is
499 a complex type (i.e. non-primitive) in its <strong>serialized</strong> JSON
500 form. The default implementation of map serialization uses <code>toString()</code>
501 on the key; however, when this is called then one of the following cases
502 apply:
503
504 <h3>Maps as JSON objects</h3>
505 For this case, assume that a type adapter is registered to serialize and
506 deserialize some <code>Point</code> class, which contains an x and y coordinate,
507 to/from the JSON Primitive string value <code>"(x,y)"</code>. The Java map would
508 then be serialized as a <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.
509
510 <p>Below is an example:
511 <pre> <code>Gson gson = new GsonBuilder()
512 .register(Point.class, new MyPointTypeAdapter())
513 .enableComplexMapKeySerialization()
514 .create();
515
516 Map&lt;Point, String&gt; original = new LinkedHashMap&lt;Point, String&gt;();
517 original.put(new Point(5, 6), "a");
518 original.put(new Point(8, 8), "b");
519 System.out.println(gson.toJson(original, type));
520 </code></pre>
521 The above code prints this JSON object:<pre> <code>{
522 "(5,6)": "a",
523 "(8,8)": "b"
524 }
525 </code></pre>
526
527 <h3>Maps as JSON arrays</h3>
528 For this case, assume that a type adapter was NOT registered for some
529 <code>Point</code> class, but rather the default Gson serialization is applied.
530 In this case, some <code>new Point(2,3)</code> would serialize as <code>{"x":2,"y":5}</code>.
531
532 <p>Given the assumption above, a <code>Map&lt;Point, String&gt;</code> will be
533 serialize as an array of arrays (can be viewed as an entry set of pairs).
534
535 <p>Below is an example of serializing complex types as JSON arrays:
536 <pre> <code>Gson gson = new GsonBuilder()
537 .enableComplexMapKeySerialization()
538 .create();
539
540 Map&lt;Point, String&gt; original = new LinkedHashMap&lt;Point, String&gt;();
541 original.put(new Point(5, 6), "a");
542 original.put(new Point(8, 8), "b");
543 System.out.println(gson.toJson(original, type));
544 </code>
545
546 The JSON output would look as follows:
547 <pre> <code>[
548 [
549 {
550 "x": 5,
551 "y": 6
552 },
553 "a"
554 ],
555 [
556 {
557 "x": 8,
558 "y": 8
559 },
560 "b"
561 ]
562 ]
563 </code></pre>
564 <P>
565 <DD><DL>
566
567 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
568 <DD>1.7</DD>
569 </DL>
570 </DD>
571 </DL>
572 <HR>
573
574 <A NAME="disableInnerClassSerialization()"><!-- --></A><H3>
575 disableInnerClassSerialization</H3>
576 <PRE>
577 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>disableInnerClassSerialization</B>()</PRE>
578 <DL>
579 <DD>Configures Gson to exclude inner classes during serialization.
580 <P>
581 <DD><DL>
582
583 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
584 <DD>1.3</DD>
585 </DL>
586 </DD>
587 </DL>
588 <HR>
589
590 <A NAME="setLongSerializationPolicy(com.google.gson.LongSerializationPolicy)"><!-- --></A><H3>
591 setLongSerializationPolicy</H3>
592 <PRE>
593 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setLongSerializationPolicy</B>(<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&nbsp;serializationPolicy)</PRE>
594 <DL>
595 <DD>Configures Gson to apply a specific serialization policy for <code>Long</code> and <code>long</code>
596 objects.
597 <P>
598 <DD><DL>
599 <DT><B>Parameters:</B><DD><CODE>serializationPolicy</CODE> - the particular policy to use for serializing longs.
600 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
601 <DD>1.3</DD>
602 </DL>
603 </DD>
604 </DL>
605 <HR>
606
607 <A NAME="setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)"><!-- --></A><H3>
608 setFieldNamingPolicy</H3>
609 <PRE>
610 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setFieldNamingPolicy</B>(<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&nbsp;namingConvention)</PRE>
611 <DL>
612 <DD>Configures Gson to apply a specific naming policy to an object's field during serialization
613 and deserialization.
614 <P>
615 <DD><DL>
616 <DT><B>Parameters:</B><DD><CODE>namingConvention</CODE> - the JSON field naming convention to use for serialization and
617 deserialization.
618 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern</DL>
619 </DD>
620 </DL>
621 <HR>
622
623 <A NAME="setFieldNamingStrategy(com.google.gson.FieldNamingStrategy)"><!-- --></A><H3>
624 setFieldNamingStrategy</H3>
625 <PRE>
626 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setFieldNamingStrategy</B>(<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>&nbsp;fieldNamingStrategy)</PRE>
627 <DL>
628 <DD>Configures Gson to apply a specific naming policy strategy to an object's field during
629 serialization and deserialization.
630 <P>
631 <DD><DL>
632 <DT><B>Parameters:</B><DD><CODE>fieldNamingStrategy</CODE> - the actual naming strategy to apply to the fields
633 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
634 <DD>1.3</DD>
635 </DL>
636 </DD>
637 </DL>
638 <HR>
639
640 <A NAME="setExclusionStrategies(com.google.gson.ExclusionStrategy...)"><!-- --></A><H3>
641 setExclusionStrategies</H3>
642 <PRE>
643 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setExclusionStrategies</B>(<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>...&nbsp;strategies)</PRE>
644 <DL>
645 <DD>Configures Gson to apply a set of exclusion strategies during both serialization and
646 deserialization. Each of the <code>strategies</code> will be applied as a disjunction rule.
647 This means that if one of the <code>strategies</code> suggests that a field (or class) should be
648 skipped then that field (or object) is skipped during serializaiton/deserialization.
649 <P>
650 <DD><DL>
651 <DT><B>Parameters:</B><DD><CODE>strategies</CODE> - the set of strategy object to apply during object (de)serialization.
652 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
653 <DD>1.4</DD>
654 </DL>
655 </DD>
656 </DL>
657 <HR>
658
659 <A NAME="addSerializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><!-- --></A><H3>
660 addSerializationExclusionStrategy</H3>
661 <PRE>
662 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>addSerializationExclusionStrategy</B>(<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</PRE>
663 <DL>
664 <DD>Configures Gson to apply the passed in exclusion strategy during serialization.
665 If this method is invoked numerous times with different exclusion strategy objects
666 then the exclusion strategies that were added will be applied as a disjunction rule.
667 This means that if one of the added exclusion strategies suggests that a field (or
668 class) should be skipped then that field (or object) is skipped during its
669 serialization.
670 <P>
671 <DD><DL>
672 <DT><B>Parameters:</B><DD><CODE>strategy</CODE> - an exclusion strategy to apply during serialization.
673 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
674 <DD>1.7</DD>
675 </DL>
676 </DD>
677 </DL>
678 <HR>
679
680 <A NAME="addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><!-- --></A><H3>
681 addDeserializationExclusionStrategy</H3>
682 <PRE>
683 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>addDeserializationExclusionStrategy</B>(<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</PRE>
684 <DL>
685 <DD>Configures Gson to apply the passed in exclusion strategy during deserialization.
686 If this method is invoked numerous times with different exclusion strategy objects
687 then the exclusion strategies that were added will be applied as a disjunction rule.
688 This means that if one of the added exclusion strategies suggests that a field (or
689 class) should be skipped then that field (or object) is skipped during its
690 deserialization.
691 <P>
692 <DD><DL>
693 <DT><B>Parameters:</B><DD><CODE>strategy</CODE> - an exclusion strategy to apply during deserialization.
694 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
695 <DD>1.7</DD>
696 </DL>
697 </DD>
698 </DL>
699 <HR>
700
701 <A NAME="setPrettyPrinting()"><!-- --></A><H3>
702 setPrettyPrinting</H3>
703 <PRE>
704 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setPrettyPrinting</B>()</PRE>
705 <DL>
706 <DD>Configures Gson to output Json that fits in a page for pretty printing. This option only
707 affects Json serialization.
708 <P>
709 <DD><DL>
710
711 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern</DL>
712 </DD>
713 </DL>
714 <HR>
715
716 <A NAME="disableHtmlEscaping()"><!-- --></A><H3>
717 disableHtmlEscaping</H3>
718 <PRE>
719 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>disableHtmlEscaping</B>()</PRE>
720 <DL>
721 <DD>By default, Gson escapes HTML characters such as &lt; &gt; etc. Use this option to configure
722 Gson to pass-through HTML characters as is.
723 <P>
724 <DD><DL>
725
726 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
727 <DD>1.3</DD>
728 </DL>
729 </DD>
730 </DL>
731 <HR>
732
733 <A NAME="setDateFormat(java.lang.String)"><!-- --></A><H3>
734 setDateFormat</H3>
735 <PRE>
736 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setDateFormat</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;pattern)</PRE>
737 <DL>
738 <DD>Configures Gson to serialize <code>Date</code> objects according to the pattern provided. You can
739 call this method or <A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(int)"><CODE>setDateFormat(int)</CODE></A> multiple times, but only the last invocation
740 will be used to decide the serialization format.
741
742 <p>The date format will be used to serialize and deserialize <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Date.html?is-external=true" title="class or interface in java.util"><CODE>Date</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/sql/Timestamp.html?is-external=true" title="class or interface in java.sql"><CODE>Timestamp</CODE></A> and <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/sql/Date.html?is-external=true" title="class or interface in java.sql"><CODE>Date</CODE></A>.
743
744 <p>Note that this pattern must abide by the convention provided by <code>SimpleDateFormat</code>
745 class. See the documentation in <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/text/SimpleDateFormat.html?is-external=true" title="class or interface in java.text"><CODE>SimpleDateFormat</CODE></A> for more information on
746 valid date and time patterns.</p>
747 <P>
748 <DD><DL>
749 <DT><B>Parameters:</B><DD><CODE>pattern</CODE> - the pattern that dates will be serialized/deserialized to/from
750 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
751 <DD>1.2</DD>
752 </DL>
753 </DD>
754 </DL>
755 <HR>
756
757 <A NAME="setDateFormat(int)"><!-- --></A><H3>
758 setDateFormat</H3>
759 <PRE>
760 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setDateFormat</B>(int&nbsp;style)</PRE>
761 <DL>
762 <DD>Configures Gson to to serialize <code>Date</code> objects according to the style value provided.
763 You can call this method or <A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(java.lang.String)"><CODE>setDateFormat(String)</CODE></A> multiple times, but only the last
764 invocation will be used to decide the serialization format.
765
766 <p>Note that this style value should be one of the predefined constants in the
767 <code>DateFormat</code> class. See the documentation in <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/text/DateFormat.html?is-external=true" title="class or interface in java.text"><CODE>DateFormat</CODE></A> for more
768 information on the valid style constants.</p>
769 <P>
770 <DD><DL>
771 <DT><B>Parameters:</B><DD><CODE>style</CODE> - the predefined date style that date objects will be serialized/deserialized
772 to/from
773 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
774 <DD>1.2</DD>
775 </DL>
776 </DD>
777 </DL>
778 <HR>
779
780 <A NAME="setDateFormat(int, int)"><!-- --></A><H3>
781 setDateFormat</H3>
782 <PRE>
783 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>setDateFormat</B>(int&nbsp;dateStyle,
784 int&nbsp;timeStyle)</PRE>
785 <DL>
786 <DD>Configures Gson to to serialize <code>Date</code> objects according to the style value provided.
787 You can call this method or <A HREF="../../../com/google/gson/GsonBuilder.html#setDateFormat(java.lang.String)"><CODE>setDateFormat(String)</CODE></A> multiple times, but only the last
788 invocation will be used to decide the serialization format.
789
790 <p>Note that this style value should be one of the predefined constants in the
791 <code>DateFormat</code> class. See the documentation in <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/text/DateFormat.html?is-external=true" title="class or interface in java.text"><CODE>DateFormat</CODE></A> for more
792 information on the valid style constants.</p>
793 <P>
794 <DD><DL>
795 <DT><B>Parameters:</B><DD><CODE>dateStyle</CODE> - the predefined date style that date objects will be serialized/deserialized
796 to/from<DD><CODE>timeStyle</CODE> - the predefined style for the time portion of the date objects
797 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
798 <DD>1.2</DD>
799 </DL>
800 </DD>
801 </DL>
802 <HR>
803
804 <A NAME="registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)"><!-- --></A><H3>
805 registerTypeAdapter</H3>
806 <PRE>
807 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>registerTypeAdapter</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type,
808 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;typeAdapter)</PRE>
809 <DL>
810 <DD>Configures Gson for custom serialization or deserialization. This method combines the
811 registration of an <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A>, <A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><CODE>InstanceCreator</CODE></A>, <A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><CODE>JsonSerializer</CODE></A>, and a
812 <A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><CODE>JsonDeserializer</CODE></A>. It is best used when a single object <code>typeAdapter</code> implements
813 all the required interfaces for custom serialization with Gson. If a type adapter was
814 previously registered for the specified <code>type</code>, it is overwritten.
815
816 <p>This registers the type specified and no other types: you must manually register related
817 types! For example, applications registering <code>boolean.class</code> should also register <code>Boolean.class</code>.
818 <P>
819 <DD><DL>
820 <DT><B>Parameters:</B><DD><CODE>type</CODE> - the type definition for the type adapter being registered<DD><CODE>typeAdapter</CODE> - This object must implement at least one of the <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A>,
821 <A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><CODE>InstanceCreator</CODE></A>, <A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><CODE>JsonSerializer</CODE></A>, and a <A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><CODE>JsonDeserializer</CODE></A> interfaces.
822 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern</DL>
823 </DD>
824 </DL>
825 <HR>
826
827 <A NAME="registerTypeAdapterFactory(com.google.gson.TypeAdapterFactory)"><!-- --></A><H3>
828 registerTypeAdapterFactory</H3>
829 <PRE>
830 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>registerTypeAdapterFactory</B>(<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;factory)</PRE>
831 <DL>
832 <DD>Register a factory for type adapters. Registering a factory is useful when the type
833 adapter needs to be configured based on the type of the field being processed. Gson
834 is designed to handle a large number of factories, so you should consider registering
835 them to be at par with registering an individual type adapter.
836 <P>
837 <DD><DL>
838 <DT><B>Since:</B></DT>
839 <DD>2.1</DD>
840 </DL>
841 </DD>
842 </DL>
843 <HR>
844
845 <A NAME="registerTypeHierarchyAdapter(java.lang.Class, java.lang.Object)"><!-- --></A><H3>
846 registerTypeHierarchyAdapter</H3>
847 <PRE>
848 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>registerTypeHierarchyAdapter</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;baseType,
849 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;typeAdapter)</PRE>
850 <DL>
851 <DD>Configures Gson for custom serialization or deserialization for an inheritance type hierarchy.
852 This method combines the registration of a <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A>, <A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><CODE>JsonSerializer</CODE></A> and
853 a <A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><CODE>JsonDeserializer</CODE></A>. If a type adapter was previously registered for the specified
854 type hierarchy, it is overridden. If a type adapter is registered for a specific type in
855 the type hierarchy, it will be invoked instead of the one registered for the type hierarchy.
856 <P>
857 <DD><DL>
858 <DT><B>Parameters:</B><DD><CODE>baseType</CODE> - the class definition for the type adapter being registered for the base class
859 or interface<DD><CODE>typeAdapter</CODE> - This object must implement at least one of <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A>,
860 <A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><CODE>JsonSerializer</CODE></A> or <A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><CODE>JsonDeserializer</CODE></A> interfaces.
861 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
862 <DD>1.7</DD>
863 </DL>
864 </DD>
865 </DL>
866 <HR>
867
868 <A NAME="serializeSpecialFloatingPointValues()"><!-- --></A><H3>
869 serializeSpecialFloatingPointValues</H3>
870 <PRE>
871 public <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> <B>serializeSpecialFloatingPointValues</B>()</PRE>
872 <DL>
873 <DD>Section 2.4 of <a href="http://www.ietf.org/rfc/rfc4627.txt">JSON specification</a> disallows
874 special double values (NaN, Infinity, -Infinity). However,
875 <a href="http://www.ecma-international.org/publications/files/ECMA-ST/Ecma-262.pdf">Javascript
876 specification</a> (see section 4.3.20, 4.3.22, 4.3.23) allows these values as valid Javascript
877 values. Moreover, most JavaScript engines will accept these special values in JSON without
878 problem. So, at a practical level, it makes sense to accept these values as valid JSON even
879 though JSON specification disallows them.
880
881 <p>Gson always accepts these special values during deserialization. However, it outputs
882 strictly compliant JSON. Hence, if it encounters a float value <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Float.html?is-external=true#NaN" title="class or interface in java.lang"><CODE>Float.NaN</CODE></A>,
883 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Float.html?is-external=true#POSITIVE_INFINITY" title="class or interface in java.lang"><CODE>Float.POSITIVE_INFINITY</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Float.html?is-external=true#NEGATIVE_INFINITY" title="class or interface in java.lang"><CODE>Float.NEGATIVE_INFINITY</CODE></A>, or a double value
884 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#NaN" title="class or interface in java.lang"><CODE>Double.NaN</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#POSITIVE_INFINITY" title="class or interface in java.lang"><CODE>Double.POSITIVE_INFINITY</CODE></A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#NEGATIVE_INFINITY" title="class or interface in java.lang"><CODE>Double.NEGATIVE_INFINITY</CODE></A>, it
885 will throw an <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalArgumentException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalArgumentException</CODE></A>. This method provides a way to override the
886 default behavior when you know that the JSON receiver will be able to handle these special
887 values.
888 <P>
889 <DD><DL>
890
891 <DT><B>Returns:</B><DD>a reference to this <code>GsonBuilder</code> object to fulfill the "Builder" pattern<DT><B>Since:</B></DT>
892 <DD>1.3</DD>
893 </DL>
894 </DD>
895 </DL>
896 <HR>
897
898 <A NAME="create()"><!-- --></A><H3>
899 create</H3>
900 <PRE>
901 public <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A> <B>create</B>()</PRE>
902 <DL>
903 <DD>Creates a <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance based on the current configuration. This method is free of
904 side-effects to this <code>GsonBuilder</code> instance and hence can be called multiple times.
905 <P>
906 <DD><DL>
907
908 <DT><B>Returns:</B><DD>an instance of Gson configured with the options currently set in this builder</DL>
909 </DD>
910 </DL>
911 <!-- ========= END OF CLASS DATA ========= -->
912 <HR>
913
914
915 <!-- ======= START OF BOTTOM NAVBAR ====== -->
916 <A NAME="navbar_bottom"><!-- --></A>
917 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
918 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
919 <TR>
920 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
921 <A NAME="navbar_bottom_firstrow"><!-- --></A>
922 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
923 <TR ALIGN="center" VALIGN="top">
924 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
925 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
926 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
927 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/GsonBuilder.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
928 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
929 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
930 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
931 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
932 </TR>
933 </TABLE>
934 </TD>
935 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
936 </EM>
937 </TD>
938 </TR>
939
940 <TR>
941 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
942 &nbsp;<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
943 &nbsp;<A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
944 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
945 <A HREF="../../../index.html?com/google/gson/GsonBuilder.html" target="_top"><B>FRAMES</B></A> &nbsp;
946 &nbsp;<A HREF="GsonBuilder.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
947 &nbsp;<SCRIPT type="text/javascript">
948 <!--
949 if(window==top) {
950 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
951 }
952 //-->
953 </SCRIPT>
954 <NOSCRIPT>
955 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
956 </NOSCRIPT>
957
958
959 </FONT></TD>
960 </TR>
961 <TR>
962 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
963 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
964 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
965 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
966 </TR>
967 </TABLE>
968 <A NAME="skip-navbar_bottom"></A>
969 <!-- ======== END OF BOTTOM NAVBAR ======= -->
970
971 <HR>
972 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
973 </BODY>
974 </HTML>
+0
-275
gson/docs/javadocs/com/google/gson/InstanceCreator.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 InstanceCreator (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="InstanceCreator (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/InstanceCreator.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/InstanceCreator.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="InstanceCreator.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface InstanceCreator&lt;T&gt;</H2>
94 <DL>
95 <DT><DT><B>Type Parameters:</B><DD><CODE>T</CODE> - the type of object that will be created by this implementation.</DL>
96 <HR>
97 <DL>
98 <DT><PRE>public interface <B>InstanceCreator&lt;T&gt;</B></DL>
99 </PRE>
100
101 <P>
102 This interface is implemented to create instances of a class that does not define a no-args
103 constructor. If you can modify the class, you should instead add a private, or public
104 no-args constructor. However, that is not possible for library classes, such as JDK classes, or
105 a third-party library that you do not have source-code of. In such cases, you should define an
106 instance creator for the class. Implementations of this interface should be registered with
107 <A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)"><CODE>GsonBuilder.registerTypeAdapter(Type, Object)</CODE></A> method before Gson will be able to use
108 them.
109 <p>Let us look at an example where defining an InstanceCreator might be useful. The
110 <code>Id</code> class defined below does not have a default no-args constructor.</p>
111
112 <pre>
113 public class Id&lt;T&gt; {
114 private final Class&lt;T&gt; clazz;
115 private final long value;
116 public Id(Class&lt;T&gt; clazz, long value) {
117 this.clazz = clazz;
118 this.value = value;
119 }
120 }
121 </pre>
122
123 <p>If Gson encounters an object of type <code>Id</code> during deserialization, it will throw an
124 exception. The easiest way to solve this problem will be to add a (public or private) no-args
125 constructor as follows:</p>
126
127 <pre>
128 private Id() {
129 this(Object.class, 0L);
130 }
131 </pre>
132
133 <p>However, let us assume that the developer does not have access to the source-code of the
134 <code>Id</code> class, or does not want to define a no-args constructor for it. The developer
135 can solve this problem by defining an <code>InstanceCreator</code> for <code>Id</code>:</p>
136
137 <pre>
138 class IdInstanceCreator implements InstanceCreator&lt;Id&gt; {
139 public Id createInstance(Type type) {
140 return new Id(Object.class, 0L);
141 }
142 }
143 </pre>
144
145 <p>Note that it does not matter what the fields of the created instance contain since Gson will
146 overwrite them with the deserialized values specified in Json. You should also ensure that a
147 <i>new</i> object is returned, not a common object since its fields will be overwritten.
148 The developer will need to register <code>IdInstanceCreator</code> with Gson as follows:</p>
149
150 <pre>
151 Gson gson = new GsonBuilder().registerTypeAdapter(Id.class, new IdInstanceCreator()).create();
152 </pre>
153 <P>
154
155 <P>
156 <DL>
157 <DT><B>Author:</B></DT>
158 <DD>Inderjeet Singh, Joel Leitch</DD>
159 </DL>
160 <HR>
161
162 <P>
163
164 <!-- ========== METHOD SUMMARY =========== -->
165
166 <A NAME="method_summary"><!-- --></A>
167 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
168 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
169 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
170 <B>Method Summary</B></FONT></TH>
171 </TR>
172 <TR BGCOLOR="white" CLASS="TableRowColor">
173 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
174 <CODE>&nbsp;<A HREF="../../../com/google/gson/InstanceCreator.html" title="type parameter in InstanceCreator">T</A></CODE></FONT></TD>
175 <TD><CODE><B><A HREF="../../../com/google/gson/InstanceCreator.html#createInstance(java.lang.reflect.Type)">createInstance</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type)</CODE>
176
177 <BR>
178 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during deserialization to create an instance of the
179 specified type.</TD>
180 </TR>
181 </TABLE>
182 &nbsp;
183 <P>
184
185 <!-- ============ METHOD DETAIL ========== -->
186
187 <A NAME="method_detail"><!-- --></A>
188 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
189 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
190 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
191 <B>Method Detail</B></FONT></TH>
192 </TR>
193 </TABLE>
194
195 <A NAME="createInstance(java.lang.reflect.Type)"><!-- --></A><H3>
196 createInstance</H3>
197 <PRE>
198 <A HREF="../../../com/google/gson/InstanceCreator.html" title="type parameter in InstanceCreator">T</A> <B>createInstance</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type)</PRE>
199 <DL>
200 <DD>Gson invokes this call-back method during deserialization to create an instance of the
201 specified type. The fields of the returned instance are overwritten with the data present
202 in the Json. Since the prior contents of the object are destroyed and overwritten, do not
203 return an instance that is useful elsewhere. In particular, do not return a common instance,
204 always use <code>new</code> to create a new instance.
205 <P>
206 <DD><DL>
207 <DT><B>Parameters:</B><DD><CODE>type</CODE> - the parameterized T represented as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect"><CODE>Type</CODE></A>.
208 <DT><B>Returns:</B><DD>a default object instance of type T.</DL>
209 </DD>
210 </DL>
211 <!-- ========= END OF CLASS DATA ========= -->
212 <HR>
213
214
215 <!-- ======= START OF BOTTOM NAVBAR ====== -->
216 <A NAME="navbar_bottom"><!-- --></A>
217 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
218 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
219 <TR>
220 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
221 <A NAME="navbar_bottom_firstrow"><!-- --></A>
222 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
223 <TR ALIGN="center" VALIGN="top">
224 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
225 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
226 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
227 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/InstanceCreator.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
228 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
229 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
230 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
231 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
232 </TR>
233 </TABLE>
234 </TD>
235 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
236 </EM>
237 </TD>
238 </TR>
239
240 <TR>
241 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
242 &nbsp;<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
243 &nbsp;<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
244 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
245 <A HREF="../../../index.html?com/google/gson/InstanceCreator.html" target="_top"><B>FRAMES</B></A> &nbsp;
246 &nbsp;<A HREF="InstanceCreator.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
247 &nbsp;<SCRIPT type="text/javascript">
248 <!--
249 if(window==top) {
250 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
251 }
252 //-->
253 </SCRIPT>
254 <NOSCRIPT>
255 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
256 </NOSCRIPT>
257
258
259 </FONT></TD>
260 </TR>
261 <TR>
262 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
263 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
264 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
265 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
266 </TR>
267 </TABLE>
268 <A NAME="skip-navbar_bottom"></A>
269 <!-- ======== END OF BOTTOM NAVBAR ======= -->
270
271 <HR>
272 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
273 </BODY>
274 </HTML>
+0
-892
gson/docs/javadocs/com/google/gson/JsonArray.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonArray (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonArray (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonArray.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonArray.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonArray.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonArray</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">com.google.gson.JsonElement</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonArray</B>
98 </PRE>
99 <DL>
100 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</DD>
101 </DL>
102 <HR>
103 <DL>
104 <DT><PRE>public final class <B>JsonArray</B><DT>extends <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A><DT>implements <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</DL>
105 </PRE>
106
107 <P>
108 A class representing an array type in Json. An array is a list of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s each of
109 which can be of a different type. This is an ordered list, meaning that the order in which
110 elements are added is preserved.
111 <P>
112
113 <P>
114 <DL>
115 <DT><B>Author:</B></DT>
116 <DD>Inderjeet Singh, Joel Leitch</DD>
117 </DL>
118 <HR>
119
120 <P>
121
122 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
123
124 <A NAME="constructor_summary"><!-- --></A>
125 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
126 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
127 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
128 <B>Constructor Summary</B></FONT></TH>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#JsonArray()">JsonArray</A></B>()</CODE>
132
133 <BR>
134 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates an empty JsonArray.</TD>
135 </TR>
136 </TABLE>
137 &nbsp;
138 <!-- ========== METHOD SUMMARY =========== -->
139
140 <A NAME="method_summary"><!-- --></A>
141 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
142 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
143 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
144 <B>Method Summary</B></FONT></TH>
145 </TR>
146 <TR BGCOLOR="white" CLASS="TableRowColor">
147 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
148 <CODE>&nbsp;void</CODE></FONT></TD>
149 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#add(com.google.gson.JsonElement)">add</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
150
151 <BR>
152 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds the specified element to self.</TD>
153 </TR>
154 <TR BGCOLOR="white" CLASS="TableRowColor">
155 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
156 <CODE>&nbsp;void</CODE></FONT></TD>
157 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#addAll(com.google.gson.JsonArray)">addAll</A></B>(<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>&nbsp;array)</CODE>
158
159 <BR>
160 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds all the elements of the specified array to self.</TD>
161 </TR>
162 <TR BGCOLOR="white" CLASS="TableRowColor">
163 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
164 <CODE>&nbsp;boolean</CODE></FONT></TD>
165 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#contains(com.google.gson.JsonElement)">contains</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
166
167 <BR>
168 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if this array contains the specified element.</TD>
169 </TR>
170 <TR BGCOLOR="white" CLASS="TableRowColor">
171 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
172 <CODE>&nbsp;boolean</CODE></FONT></TD>
173 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#equals(java.lang.Object)">equals</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;o)</CODE>
174
175 <BR>
176 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
177 </TR>
178 <TR BGCOLOR="white" CLASS="TableRowColor">
179 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
180 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
181 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#get(int)">get</A></B>(int&nbsp;i)</CODE>
182
183 <BR>
184 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the ith element of the array.</TD>
185 </TR>
186 <TR BGCOLOR="white" CLASS="TableRowColor">
187 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
188 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math">BigDecimal</A></CODE></FONT></TD>
189 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsBigDecimal()">getAsBigDecimal</A></B>()</CODE>
190
191 <BR>
192 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A> if it contains a single element.</TD>
193 </TR>
194 <TR BGCOLOR="white" CLASS="TableRowColor">
195 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
196 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</A></CODE></FONT></TD>
197 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsBigInteger()">getAsBigInteger</A></B>()</CODE>
198
199 <BR>
200 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A> if it contains a single element.</TD>
201 </TR>
202 <TR BGCOLOR="white" CLASS="TableRowColor">
203 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
204 <CODE>&nbsp;boolean</CODE></FONT></TD>
205 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsBoolean()">getAsBoolean</A></B>()</CODE>
206
207 <BR>
208 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a boolean if it contains a single element.</TD>
209 </TR>
210 <TR BGCOLOR="white" CLASS="TableRowColor">
211 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
212 <CODE>&nbsp;byte</CODE></FONT></TD>
213 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsByte()">getAsByte</A></B>()</CODE>
214
215 <BR>
216 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive byte value.</TD>
217 </TR>
218 <TR BGCOLOR="white" CLASS="TableRowColor">
219 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
220 <CODE>&nbsp;char</CODE></FONT></TD>
221 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsCharacter()">getAsCharacter</A></B>()</CODE>
222
223 <BR>
224 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive character value.</TD>
225 </TR>
226 <TR BGCOLOR="white" CLASS="TableRowColor">
227 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
228 <CODE>&nbsp;double</CODE></FONT></TD>
229 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsDouble()">getAsDouble</A></B>()</CODE>
230
231 <BR>
232 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a double if it contains a single element.</TD>
233 </TR>
234 <TR BGCOLOR="white" CLASS="TableRowColor">
235 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
236 <CODE>&nbsp;float</CODE></FONT></TD>
237 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsFloat()">getAsFloat</A></B>()</CODE>
238
239 <BR>
240 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a float if it contains a single element.</TD>
241 </TR>
242 <TR BGCOLOR="white" CLASS="TableRowColor">
243 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
244 <CODE>&nbsp;int</CODE></FONT></TD>
245 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsInt()">getAsInt</A></B>()</CODE>
246
247 <BR>
248 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as an integer if it contains a single element.</TD>
249 </TR>
250 <TR BGCOLOR="white" CLASS="TableRowColor">
251 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
252 <CODE>&nbsp;long</CODE></FONT></TD>
253 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsLong()">getAsLong</A></B>()</CODE>
254
255 <BR>
256 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a long if it contains a single element.</TD>
257 </TR>
258 <TR BGCOLOR="white" CLASS="TableRowColor">
259 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
260 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A></CODE></FONT></TD>
261 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsNumber()">getAsNumber</A></B>()</CODE>
262
263 <BR>
264 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A> if it contains a single element.</TD>
265 </TR>
266 <TR BGCOLOR="white" CLASS="TableRowColor">
267 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
268 <CODE>&nbsp;short</CODE></FONT></TD>
269 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsShort()">getAsShort</A></B>()</CODE>
270
271 <BR>
272 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a primitive short if it contains a single element.</TD>
273 </TR>
274 <TR BGCOLOR="white" CLASS="TableRowColor">
275 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
276 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
277 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#getAsString()">getAsString</A></B>()</CODE>
278
279 <BR>
280 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang"><CODE>String</CODE></A> if it contains a single element.</TD>
281 </TR>
282 <TR BGCOLOR="white" CLASS="TableRowColor">
283 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
284 <CODE>&nbsp;int</CODE></FONT></TD>
285 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#hashCode()">hashCode</A></B>()</CODE>
286
287 <BR>
288 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
289 </TR>
290 <TR BGCOLOR="white" CLASS="TableRowColor">
291 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
292 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</CODE></FONT></TD>
293 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#iterator()">iterator</A></B>()</CODE>
294
295 <BR>
296 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an iterator to navigate the elemetns of the array.</TD>
297 </TR>
298 <TR BGCOLOR="white" CLASS="TableRowColor">
299 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
300 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
301 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#remove(int)">remove</A></B>(int&nbsp;index)</CODE>
302
303 <BR>
304 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the element at the specified position in this array.</TD>
305 </TR>
306 <TR BGCOLOR="white" CLASS="TableRowColor">
307 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
308 <CODE>&nbsp;boolean</CODE></FONT></TD>
309 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#remove(com.google.gson.JsonElement)">remove</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
310
311 <BR>
312 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the first occurrence of the specified element from this array, if it is present.</TD>
313 </TR>
314 <TR BGCOLOR="white" CLASS="TableRowColor">
315 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
316 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
317 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#set(int, com.google.gson.JsonElement)">set</A></B>(int&nbsp;index,
318 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
319
320 <BR>
321 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Replaces the element at the specified position in this array with the specified element.</TD>
322 </TR>
323 <TR BGCOLOR="white" CLASS="TableRowColor">
324 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
325 <CODE>&nbsp;int</CODE></FONT></TD>
326 <TD><CODE><B><A HREF="../../../com/google/gson/JsonArray.html#size()">size</A></B>()</CODE>
327
328 <BR>
329 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of elements in the array.</TD>
330 </TR>
331 </TABLE>
332 &nbsp;<A NAME="methods_inherited_from_class_com.google.gson.JsonElement"><!-- --></A>
333 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
334 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
335 <TH ALIGN="left"><B>Methods inherited from class com.google.gson.<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></B></TH>
336 </TR>
337 <TR BGCOLOR="white" CLASS="TableRowColor">
338 <TD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsJsonArray()">getAsJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonNull()">getAsJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonObject()">getAsJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonPrimitive()">getAsJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonArray()">isJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonNull()">isJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonObject()">isJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonPrimitive()">isJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#toString()">toString</A></CODE></TD>
339 </TR>
340 </TABLE>
341 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
342 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
343 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
344 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
345 </TR>
346 <TR BGCOLOR="white" CLASS="TableRowColor">
347 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
348 </TR>
349 </TABLE>
350 &nbsp;
351 <P>
352
353 <!-- ========= CONSTRUCTOR DETAIL ======== -->
354
355 <A NAME="constructor_detail"><!-- --></A>
356 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
357 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
358 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
359 <B>Constructor Detail</B></FONT></TH>
360 </TR>
361 </TABLE>
362
363 <A NAME="JsonArray()"><!-- --></A><H3>
364 JsonArray</H3>
365 <PRE>
366 public <B>JsonArray</B>()</PRE>
367 <DL>
368 <DD>Creates an empty JsonArray.
369 <P>
370 </DL>
371
372 <!-- ============ METHOD DETAIL ========== -->
373
374 <A NAME="method_detail"><!-- --></A>
375 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
376 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
377 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
378 <B>Method Detail</B></FONT></TH>
379 </TR>
380 </TABLE>
381
382 <A NAME="add(com.google.gson.JsonElement)"><!-- --></A><H3>
383 add</H3>
384 <PRE>
385 public void <B>add</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</PRE>
386 <DL>
387 <DD>Adds the specified element to self.
388 <P>
389 <DD><DL>
390 </DL>
391 </DD>
392 <DD><DL>
393 <DT><B>Parameters:</B><DD><CODE>element</CODE> - the element that needs to be added to the array.</DL>
394 </DD>
395 </DL>
396 <HR>
397
398 <A NAME="addAll(com.google.gson.JsonArray)"><!-- --></A><H3>
399 addAll</H3>
400 <PRE>
401 public void <B>addAll</B>(<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>&nbsp;array)</PRE>
402 <DL>
403 <DD>Adds all the elements of the specified array to self.
404 <P>
405 <DD><DL>
406 </DL>
407 </DD>
408 <DD><DL>
409 <DT><B>Parameters:</B><DD><CODE>array</CODE> - the array whose elements need to be added to the array.</DL>
410 </DD>
411 </DL>
412 <HR>
413
414 <A NAME="set(int, com.google.gson.JsonElement)"><!-- --></A><H3>
415 set</H3>
416 <PRE>
417 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>set</B>(int&nbsp;index,
418 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</PRE>
419 <DL>
420 <DD>Replaces the element at the specified position in this array with the specified element.
421 Element can be null.
422 <P>
423 <DD><DL>
424 </DL>
425 </DD>
426 <DD><DL>
427 <DT><B>Parameters:</B><DD><CODE>index</CODE> - index of the element to replace<DD><CODE>element</CODE> - element to be stored at the specified position
428 <DT><B>Returns:</B><DD>the element previously at the specified position
429 <DT><B>Throws:</B>
430 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang">IndexOutOfBoundsException</A></CODE> - if the specified index is outside the array bounds</DL>
431 </DD>
432 </DL>
433 <HR>
434
435 <A NAME="remove(com.google.gson.JsonElement)"><!-- --></A><H3>
436 remove</H3>
437 <PRE>
438 public boolean <B>remove</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</PRE>
439 <DL>
440 <DD>Removes the first occurrence of the specified element from this array, if it is present.
441 If the array does not contain the element, it is unchanged.
442 <P>
443 <DD><DL>
444 </DL>
445 </DD>
446 <DD><DL>
447 <DT><B>Parameters:</B><DD><CODE>element</CODE> - element to be removed from this array, if present
448 <DT><B>Returns:</B><DD>true if this array contained the specified element, false otherwise<DT><B>Since:</B></DT>
449 <DD>2.3</DD>
450 </DL>
451 </DD>
452 </DL>
453 <HR>
454
455 <A NAME="remove(int)"><!-- --></A><H3>
456 remove</H3>
457 <PRE>
458 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>remove</B>(int&nbsp;index)</PRE>
459 <DL>
460 <DD>Removes the element at the specified position in this array. Shifts any subsequent elements
461 to the left (subtracts one from their indices). Returns the element that was removed from
462 the array.
463 <P>
464 <DD><DL>
465 </DL>
466 </DD>
467 <DD><DL>
468 <DT><B>Parameters:</B><DD><CODE>index</CODE> - index the index of the element to be removed
469 <DT><B>Returns:</B><DD>the element previously at the specified position
470 <DT><B>Throws:</B>
471 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang">IndexOutOfBoundsException</A></CODE> - if the specified index is outside the array bounds<DT><B>Since:</B></DT>
472 <DD>2.3</DD>
473 </DL>
474 </DD>
475 </DL>
476 <HR>
477
478 <A NAME="contains(com.google.gson.JsonElement)"><!-- --></A><H3>
479 contains</H3>
480 <PRE>
481 public boolean <B>contains</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</PRE>
482 <DL>
483 <DD>Returns true if this array contains the specified element.
484 <P>
485 <DD><DL>
486 </DL>
487 </DD>
488 <DD><DL>
489 <DT><B>Parameters:</B><DD><CODE>element</CODE> - whose presence in this array is to be tested
490 <DT><B>Returns:</B><DD>true if this array contains the specified element.<DT><B>Since:</B></DT>
491 <DD>2.3</DD>
492 </DL>
493 </DD>
494 </DL>
495 <HR>
496
497 <A NAME="size()"><!-- --></A><H3>
498 size</H3>
499 <PRE>
500 public int <B>size</B>()</PRE>
501 <DL>
502 <DD>Returns the number of elements in the array.
503 <P>
504 <DD><DL>
505 </DL>
506 </DD>
507 <DD><DL>
508
509 <DT><B>Returns:</B><DD>the number of elements in the array.</DL>
510 </DD>
511 </DL>
512 <HR>
513
514 <A NAME="iterator()"><!-- --></A><H3>
515 iterator</H3>
516 <PRE>
517 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt; <B>iterator</B>()</PRE>
518 <DL>
519 <DD>Returns an iterator to navigate the elemetns of the array. Since the array is an ordered list,
520 the iterator navigates the elements in the order they were inserted.
521 <P>
522 <DD><DL>
523 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Iterable.html?is-external=true#iterator()" title="class or interface in java.lang">iterator</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</CODE></DL>
524 </DD>
525 <DD><DL>
526
527 <DT><B>Returns:</B><DD>an iterator to navigate the elements of the array.</DL>
528 </DD>
529 </DL>
530 <HR>
531
532 <A NAME="get(int)"><!-- --></A><H3>
533 get</H3>
534 <PRE>
535 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>get</B>(int&nbsp;i)</PRE>
536 <DL>
537 <DD>Returns the ith element of the array.
538 <P>
539 <DD><DL>
540 </DL>
541 </DD>
542 <DD><DL>
543 <DT><B>Parameters:</B><DD><CODE>i</CODE> - the index of the element that is being sought.
544 <DT><B>Returns:</B><DD>the element present at the ith index.
545 <DT><B>Throws:</B>
546 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IndexOutOfBoundsException.html?is-external=true" title="class or interface in java.lang">IndexOutOfBoundsException</A></CODE> - if i is negative or greater than or equal to the
547 <A HREF="../../../com/google/gson/JsonArray.html#size()"><CODE>size()</CODE></A> of the array.</DL>
548 </DD>
549 </DL>
550 <HR>
551
552 <A NAME="getAsNumber()"><!-- --></A><H3>
553 getAsNumber</H3>
554 <PRE>
555 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A> <B>getAsNumber</B>()</PRE>
556 <DL>
557 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A> if it contains a single element.
558 <P>
559 <DD><DL>
560 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsNumber()">getAsNumber</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
561 </DD>
562 <DD><DL>
563
564 <DT><B>Returns:</B><DD>get this element as a number if it is single element array.
565 <DT><B>Throws:</B>
566 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
567 is not a valid Number.
568 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
569 </DD>
570 </DL>
571 <HR>
572
573 <A NAME="getAsString()"><!-- --></A><H3>
574 getAsString</H3>
575 <PRE>
576 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getAsString</B>()</PRE>
577 <DL>
578 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang"><CODE>String</CODE></A> if it contains a single element.
579 <P>
580 <DD><DL>
581 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsString()">getAsString</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
582 </DD>
583 <DD><DL>
584
585 <DT><B>Returns:</B><DD>get this element as a String if it is single element array.
586 <DT><B>Throws:</B>
587 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
588 is not a valid String.
589 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
590 </DD>
591 </DL>
592 <HR>
593
594 <A NAME="getAsDouble()"><!-- --></A><H3>
595 getAsDouble</H3>
596 <PRE>
597 public double <B>getAsDouble</B>()</PRE>
598 <DL>
599 <DD>convenience method to get this array as a double if it contains a single element.
600 <P>
601 <DD><DL>
602 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsDouble()">getAsDouble</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
603 </DD>
604 <DD><DL>
605
606 <DT><B>Returns:</B><DD>get this element as a double if it is single element array.
607 <DT><B>Throws:</B>
608 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
609 is not a valid double.
610 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
611 </DD>
612 </DL>
613 <HR>
614
615 <A NAME="getAsBigDecimal()"><!-- --></A><H3>
616 getAsBigDecimal</H3>
617 <PRE>
618 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math">BigDecimal</A> <B>getAsBigDecimal</B>()</PRE>
619 <DL>
620 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A> if it contains a single element.
621 <P>
622 <DD><DL>
623 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBigDecimal()">getAsBigDecimal</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
624 </DD>
625 <DD><DL>
626
627 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A> if it is single element array.
628 <DT><B>Throws:</B>
629 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.
630 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the element at index 0 is not a valid <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
631 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.<DT><B>Since:</B></DT>
632 <DD>1.2</DD>
633 </DL>
634 </DD>
635 </DL>
636 <HR>
637
638 <A NAME="getAsBigInteger()"><!-- --></A><H3>
639 getAsBigInteger</H3>
640 <PRE>
641 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</A> <B>getAsBigInteger</B>()</PRE>
642 <DL>
643 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A> if it contains a single element.
644 <P>
645 <DD><DL>
646 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBigInteger()">getAsBigInteger</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
647 </DD>
648 <DD><DL>
649
650 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A> if it is single element array.
651 <DT><B>Throws:</B>
652 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.
653 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the element at index 0 is not a valid <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
654 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.<DT><B>Since:</B></DT>
655 <DD>1.2</DD>
656 </DL>
657 </DD>
658 </DL>
659 <HR>
660
661 <A NAME="getAsFloat()"><!-- --></A><H3>
662 getAsFloat</H3>
663 <PRE>
664 public float <B>getAsFloat</B>()</PRE>
665 <DL>
666 <DD>convenience method to get this array as a float if it contains a single element.
667 <P>
668 <DD><DL>
669 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsFloat()">getAsFloat</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
670 </DD>
671 <DD><DL>
672
673 <DT><B>Returns:</B><DD>get this element as a float if it is single element array.
674 <DT><B>Throws:</B>
675 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
676 is not a valid float.
677 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
678 </DD>
679 </DL>
680 <HR>
681
682 <A NAME="getAsLong()"><!-- --></A><H3>
683 getAsLong</H3>
684 <PRE>
685 public long <B>getAsLong</B>()</PRE>
686 <DL>
687 <DD>convenience method to get this array as a long if it contains a single element.
688 <P>
689 <DD><DL>
690 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsLong()">getAsLong</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
691 </DD>
692 <DD><DL>
693
694 <DT><B>Returns:</B><DD>get this element as a long if it is single element array.
695 <DT><B>Throws:</B>
696 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
697 is not a valid long.
698 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
699 </DD>
700 </DL>
701 <HR>
702
703 <A NAME="getAsInt()"><!-- --></A><H3>
704 getAsInt</H3>
705 <PRE>
706 public int <B>getAsInt</B>()</PRE>
707 <DL>
708 <DD>convenience method to get this array as an integer if it contains a single element.
709 <P>
710 <DD><DL>
711 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsInt()">getAsInt</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
712 </DD>
713 <DD><DL>
714
715 <DT><B>Returns:</B><DD>get this element as an integer if it is single element array.
716 <DT><B>Throws:</B>
717 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
718 is not a valid integer.
719 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
720 </DD>
721 </DL>
722 <HR>
723
724 <A NAME="getAsByte()"><!-- --></A><H3>
725 getAsByte</H3>
726 <PRE>
727 public byte <B>getAsByte</B>()</PRE>
728 <DL>
729 <DD><B>Description copied from class: <CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">JsonElement</A></CODE></B></DD>
730 <DD>convenience method to get this element as a primitive byte value.
731 <P>
732 <DD><DL>
733 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">getAsByte</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
734 </DD>
735 <DD><DL>
736
737 <DT><B>Returns:</B><DD>get this element as a primitive byte value.</DL>
738 </DD>
739 </DL>
740 <HR>
741
742 <A NAME="getAsCharacter()"><!-- --></A><H3>
743 getAsCharacter</H3>
744 <PRE>
745 public char <B>getAsCharacter</B>()</PRE>
746 <DL>
747 <DD><B>Description copied from class: <CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">JsonElement</A></CODE></B></DD>
748 <DD>convenience method to get this element as a primitive character value.
749 <P>
750 <DD><DL>
751 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">getAsCharacter</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
752 </DD>
753 <DD><DL>
754
755 <DT><B>Returns:</B><DD>get this element as a primitive char value.</DL>
756 </DD>
757 </DL>
758 <HR>
759
760 <A NAME="getAsShort()"><!-- --></A><H3>
761 getAsShort</H3>
762 <PRE>
763 public short <B>getAsShort</B>()</PRE>
764 <DL>
765 <DD>convenience method to get this array as a primitive short if it contains a single element.
766 <P>
767 <DD><DL>
768 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsShort()">getAsShort</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
769 </DD>
770 <DD><DL>
771
772 <DT><B>Returns:</B><DD>get this element as a primitive short if it is single element array.
773 <DT><B>Throws:</B>
774 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
775 is not a valid short.
776 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
777 </DD>
778 </DL>
779 <HR>
780
781 <A NAME="getAsBoolean()"><!-- --></A><H3>
782 getAsBoolean</H3>
783 <PRE>
784 public boolean <B>getAsBoolean</B>()</PRE>
785 <DL>
786 <DD>convenience method to get this array as a boolean if it contains a single element.
787 <P>
788 <DD><DL>
789 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBoolean()">getAsBoolean</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
790 </DD>
791 <DD><DL>
792
793 <DT><B>Returns:</B><DD>get this element as a boolean if it is single element array.
794 <DT><B>Throws:</B>
795 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element in the array is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and
796 is not a valid boolean.
797 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the array has more than one element.</DL>
798 </DD>
799 </DL>
800 <HR>
801
802 <A NAME="equals(java.lang.Object)"><!-- --></A><H3>
803 equals</H3>
804 <PRE>
805 public boolean <B>equals</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;o)</PRE>
806 <DL>
807 <DD><DL>
808 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
809 </DD>
810 <DD><DL>
811 </DL>
812 </DD>
813 </DL>
814 <HR>
815
816 <A NAME="hashCode()"><!-- --></A><H3>
817 hashCode</H3>
818 <PRE>
819 public int <B>hashCode</B>()</PRE>
820 <DL>
821 <DD><DL>
822 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
823 </DD>
824 <DD><DL>
825 </DL>
826 </DD>
827 </DL>
828 <!-- ========= END OF CLASS DATA ========= -->
829 <HR>
830
831
832 <!-- ======= START OF BOTTOM NAVBAR ====== -->
833 <A NAME="navbar_bottom"><!-- --></A>
834 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
835 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
836 <TR>
837 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
838 <A NAME="navbar_bottom_firstrow"><!-- --></A>
839 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
840 <TR ALIGN="center" VALIGN="top">
841 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
842 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
843 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
844 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonArray.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
845 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
846 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
847 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
848 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
849 </TR>
850 </TABLE>
851 </TD>
852 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
853 </EM>
854 </TD>
855 </TR>
856
857 <TR>
858 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
859 &nbsp;<A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
860 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
861 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
862 <A HREF="../../../index.html?com/google/gson/JsonArray.html" target="_top"><B>FRAMES</B></A> &nbsp;
863 &nbsp;<A HREF="JsonArray.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
864 &nbsp;<SCRIPT type="text/javascript">
865 <!--
866 if(window==top) {
867 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
868 }
869 //-->
870 </SCRIPT>
871 <NOSCRIPT>
872 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
873 </NOSCRIPT>
874
875
876 </FONT></TD>
877 </TR>
878 <TR>
879 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
880 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
881 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
882 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
883 </TR>
884 </TABLE>
885 <A NAME="skip-navbar_bottom"></A>
886 <!-- ======== END OF BOTTOM NAVBAR ======= -->
887
888 <HR>
889 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
890 </BODY>
891 </HTML>
+0
-235
gson/docs/javadocs/com/google/gson/JsonDeserializationContext.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonDeserializationContext (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonDeserializationContext (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonDeserializationContext.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonDeserializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonDeserializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface JsonDeserializationContext</H2>
94 <HR>
95 <DL>
96 <DT><PRE>public interface <B>JsonDeserializationContext</B></DL>
97 </PRE>
98
99 <P>
100 Context for deserialization that is passed to a custom deserializer during invocation of its
101 <A HREF="../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><CODE>JsonDeserializer.deserialize(JsonElement, Type, JsonDeserializationContext)</CODE></A>
102 method.
103 <P>
104
105 <P>
106 <DL>
107 <DT><B>Author:</B></DT>
108 <DD>Inderjeet Singh, Joel Leitch</DD>
109 </DL>
110 <HR>
111
112 <P>
113
114 <!-- ========== METHOD SUMMARY =========== -->
115
116 <A NAME="method_summary"><!-- --></A>
117 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
118 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
119 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
120 <B>Method Summary</B></FONT></TH>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>
125 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
126 <TR ALIGN="right" VALIGN="">
127 <TD NOWRAP><FONT SIZE="-1">
128 <CODE>&lt;T&gt; T</CODE></FONT></TD>
129 </TR>
130 </TABLE>
131 </CODE></FONT></TD>
132 <TD><CODE><B><A HREF="../../../com/google/gson/JsonDeserializationContext.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type)">deserialize</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
133 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default deserialization on the specified object.</TD>
137 </TR>
138 </TABLE>
139 &nbsp;
140 <P>
141
142 <!-- ============ METHOD DETAIL ========== -->
143
144 <A NAME="method_detail"><!-- --></A>
145 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
146 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
147 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
148 <B>Method Detail</B></FONT></TH>
149 </TR>
150 </TABLE>
151
152 <A NAME="deserialize(com.google.gson.JsonElement, java.lang.reflect.Type)"><!-- --></A><H3>
153 deserialize</H3>
154 <PRE>
155 &lt;T&gt; T <B>deserialize</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
156 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)
157 throws <A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></PRE>
158 <DL>
159 <DD>Invokes default deserialization on the specified object. It should never be invoked on
160 the element received as a parameter of the
161 <A HREF="../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><CODE>JsonDeserializer.deserialize(JsonElement, Type, JsonDeserializationContext)</CODE></A> method. Doing
162 so will result in an infinite loop since Gson will in-turn call the custom deserializer again.
163 <P>
164 <DD><DL>
165 <DT><B>Type Parameters:</B><DD><CODE>T</CODE> - The type of the deserialized object.<DT><B>Parameters:</B><DD><CODE>json</CODE> - the parse tree.<DD><CODE>typeOfT</CODE> - type of the expected return value.
166 <DT><B>Returns:</B><DD>An object of type typeOfT.
167 <DT><B>Throws:</B>
168 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if the parse tree does not contain expected data.</DL>
169 </DD>
170 </DL>
171 <!-- ========= END OF CLASS DATA ========= -->
172 <HR>
173
174
175 <!-- ======= START OF BOTTOM NAVBAR ====== -->
176 <A NAME="navbar_bottom"><!-- --></A>
177 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
178 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
179 <TR>
180 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
181 <A NAME="navbar_bottom_firstrow"><!-- --></A>
182 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
183 <TR ALIGN="center" VALIGN="top">
184 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
185 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
186 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
187 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonDeserializationContext.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
188 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
189 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
190 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
191 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
192 </TR>
193 </TABLE>
194 </TD>
195 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
196 </EM>
197 </TD>
198 </TR>
199
200 <TR>
201 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
202 &nbsp;<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
203 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
204 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
205 <A HREF="../../../index.html?com/google/gson/JsonDeserializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
206 &nbsp;<A HREF="JsonDeserializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
207 &nbsp;<SCRIPT type="text/javascript">
208 <!--
209 if(window==top) {
210 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
211 }
212 //-->
213 </SCRIPT>
214 <NOSCRIPT>
215 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
216 </NOSCRIPT>
217
218
219 </FONT></TD>
220 </TR>
221 <TR>
222 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
223 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
224 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
225 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
226 </TR>
227 </TABLE>
228 <A NAME="skip-navbar_bottom"></A>
229 <!-- ======== END OF BOTTOM NAVBAR ======= -->
230
231 <HR>
232 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
233 </BODY>
234 </HTML>
+0
-278
gson/docs/javadocs/com/google/gson/JsonDeserializer.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonDeserializer (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonDeserializer (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonDeserializer.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonDeserializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonDeserializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface JsonDeserializer&lt;T&gt;</H2>
94 <DL>
95 <DT><DT><B>Type Parameters:</B><DD><CODE>T</CODE> - type for which the deserializer is being registered. It is possible that a
96 deserializer may be asked to deserialize a specific generic type of the T.</DL>
97 <HR>
98 <DL>
99 <DT><PRE>public interface <B>JsonDeserializer&lt;T&gt;</B></DL>
100 </PRE>
101
102 <P>
103 <p>Interface representing a custom deserializer for Json. You should write a custom
104 deserializer, if you are not happy with the default deserialization done by Gson. You will
105 also need to register this deserializer through
106 <A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)"><CODE>GsonBuilder.registerTypeAdapter(Type, Object)</CODE></A>.</p>
107
108 <p>Let us look at example where defining a deserializer will be useful. The <code>Id</code> class
109 defined below has two fields: <code>clazz</code> and <code>value</code>.</p>
110
111 <pre>
112 public class Id&lt;T&gt; {
113 private final Class&lt;T&gt; clazz;
114 private final long value;
115 public Id(Class&lt;T&gt; clazz, long value) {
116 this.clazz = clazz;
117 this.value = value;
118 }
119 public long getValue() {
120 return value;
121 }
122 }
123 </pre>
124
125 <p>The default deserialization of <code>Id(com.foo.MyObject.class, 20L)</code> will require the
126 Json string to be <code>{"clazz":com.foo.MyObject,"value":20}</code>. Suppose, you already know
127 the type of the field that the <code>Id</code> will be deserialized into, and hence just want to
128 deserialize it from a Json string <code>20</code>. You can achieve that by writing a custom
129 deserializer:</p>
130
131 <pre>
132 class IdDeserializer implements JsonDeserializer&lt;Id&gt;() {
133 public Id deserialize(JsonElement json, Type typeOfT, JsonDeserializationContext context)
134 throws JsonParseException {
135 return new Id((Class)typeOfT, id.getValue());
136 }
137 </pre>
138
139 <p>You will also need to register <code>IdDeserializer</code> with Gson as follows:</p>
140
141 <pre>
142 Gson gson = new GsonBuilder().registerTypeAdapter(Id.class, new IdDeserializer()).create();
143 </pre>
144
145 <p>New applications should prefer <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A>, whose streaming API
146 is more efficient than this interface's tree API.
147 <P>
148
149 <P>
150 <DL>
151 <DT><B>Author:</B></DT>
152 <DD>Inderjeet Singh, Joel Leitch</DD>
153 </DL>
154 <HR>
155
156 <P>
157
158 <!-- ========== METHOD SUMMARY =========== -->
159
160 <A NAME="method_summary"><!-- --></A>
161 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
162 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
163 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
164 <B>Method Summary</B></FONT></TH>
165 </TR>
166 <TR BGCOLOR="white" CLASS="TableRowColor">
167 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
168 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonDeserializer.html" title="type parameter in JsonDeserializer">T</A></CODE></FONT></TD>
169 <TD><CODE><B><A HREF="../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)">deserialize</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
170 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT,
171 <A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A>&nbsp;context)</CODE>
172
173 <BR>
174 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during deserialization when it encounters a field of the
175 specified type.</TD>
176 </TR>
177 </TABLE>
178 &nbsp;
179 <P>
180
181 <!-- ============ METHOD DETAIL ========== -->
182
183 <A NAME="method_detail"><!-- --></A>
184 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
185 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
186 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
187 <B>Method Detail</B></FONT></TH>
188 </TR>
189 </TABLE>
190
191 <A NAME="deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><!-- --></A><H3>
192 deserialize</H3>
193 <PRE>
194 <A HREF="../../../com/google/gson/JsonDeserializer.html" title="type parameter in JsonDeserializer">T</A> <B>deserialize</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
195 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT,
196 <A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A>&nbsp;context)
197 throws <A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></PRE>
198 <DL>
199 <DD>Gson invokes this call-back method during deserialization when it encounters a field of the
200 specified type.
201 <p>In the implementation of this call-back method, you should consider invoking
202 <A HREF="../../../com/google/gson/JsonDeserializationContext.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type)"><CODE>JsonDeserializationContext.deserialize(JsonElement, Type)</CODE></A> method to create objects
203 for any non-trivial field of the returned object. However, you should never invoke it on the
204 the same type passing <code>json</code> since that will cause an infinite loop (Gson will call your
205 call-back method again).
206 <P>
207 <DD><DL>
208 <DT><B>Parameters:</B><DD><CODE>json</CODE> - The Json data being deserialized<DD><CODE>typeOfT</CODE> - The type of the Object to deserialize to
209 <DT><B>Returns:</B><DD>a deserialized object of the specified type typeOfT which is a subclass of <code>T</code>
210 <DT><B>Throws:</B>
211 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if json is not in the expected format of <code>typeofT</code></DL>
212 </DD>
213 </DL>
214 <!-- ========= END OF CLASS DATA ========= -->
215 <HR>
216
217
218 <!-- ======= START OF BOTTOM NAVBAR ====== -->
219 <A NAME="navbar_bottom"><!-- --></A>
220 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
221 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
222 <TR>
223 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
224 <A NAME="navbar_bottom_firstrow"><!-- --></A>
225 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
226 <TR ALIGN="center" VALIGN="top">
227 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
228 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
229 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
230 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonDeserializer.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
231 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
232 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
233 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
234 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
235 </TR>
236 </TABLE>
237 </TD>
238 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
239 </EM>
240 </TD>
241 </TR>
242
243 <TR>
244 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
245 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
246 &nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
247 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
248 <A HREF="../../../index.html?com/google/gson/JsonDeserializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
249 &nbsp;<A HREF="JsonDeserializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
250 &nbsp;<SCRIPT type="text/javascript">
251 <!--
252 if(window==top) {
253 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
254 }
255 //-->
256 </SCRIPT>
257 <NOSCRIPT>
258 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
259 </NOSCRIPT>
260
261
262 </FONT></TD>
263 </TR>
264 <TR>
265 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
266 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
267 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
268 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
269 </TR>
270 </TABLE>
271 <A NAME="skip-navbar_bottom"></A>
272 <!-- ======== END OF BOTTOM NAVBAR ======= -->
273
274 <HR>
275 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
276 </BODY>
277 </HTML>
+0
-802
gson/docs/javadocs/com/google/gson/JsonElement.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonElement (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonElement (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonElement.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonElement.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonElement.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonElement</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonElement</B>
97 </PRE>
98 <DL>
99 <DT><B>Direct Known Subclasses:</B> <DD><A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>, <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A>, <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>, <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></DD>
100 </DL>
101 <HR>
102 <DL>
103 <DT><PRE>public abstract class <B>JsonElement</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
104 </PRE>
105
106 <P>
107 A class representing an element of Json. It could either be a <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>, a
108 <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>, a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> or a <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.
109 <P>
110
111 <P>
112 <DL>
113 <DT><B>Author:</B></DT>
114 <DD>Inderjeet Singh, Joel Leitch</DD>
115 </DL>
116 <HR>
117
118 <P>
119
120 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
121
122 <A NAME="constructor_summary"><!-- --></A>
123 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
124 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
125 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
126 <B>Constructor Summary</B></FONT></TH>
127 </TR>
128 <TR BGCOLOR="white" CLASS="TableRowColor">
129 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#JsonElement()">JsonElement</A></B>()</CODE>
130
131 <BR>
132 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
133 </TR>
134 </TABLE>
135 &nbsp;
136 <!-- ========== METHOD SUMMARY =========== -->
137
138 <A NAME="method_summary"><!-- --></A>
139 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
140 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
141 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
142 <B>Method Summary</B></FONT></TH>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
146 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math">BigDecimal</A></CODE></FONT></TD>
147 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsBigDecimal()">getAsBigDecimal</A></B>()</CODE>
148
149 <BR>
150 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.</TD>
151 </TR>
152 <TR BGCOLOR="white" CLASS="TableRowColor">
153 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
154 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</A></CODE></FONT></TD>
155 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsBigInteger()">getAsBigInteger</A></B>()</CODE>
156
157 <BR>
158 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.</TD>
159 </TR>
160 <TR BGCOLOR="white" CLASS="TableRowColor">
161 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
162 <CODE>&nbsp;boolean</CODE></FONT></TD>
163 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsBoolean()">getAsBoolean</A></B>()</CODE>
164
165 <BR>
166 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a boolean value.</TD>
167 </TR>
168 <TR BGCOLOR="white" CLASS="TableRowColor">
169 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
170 <CODE>&nbsp;byte</CODE></FONT></TD>
171 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">getAsByte</A></B>()</CODE>
172
173 <BR>
174 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive byte value.</TD>
175 </TR>
176 <TR BGCOLOR="white" CLASS="TableRowColor">
177 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
178 <CODE>&nbsp;char</CODE></FONT></TD>
179 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">getAsCharacter</A></B>()</CODE>
180
181 <BR>
182 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive character value.</TD>
183 </TR>
184 <TR BGCOLOR="white" CLASS="TableRowColor">
185 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
186 <CODE>&nbsp;double</CODE></FONT></TD>
187 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsDouble()">getAsDouble</A></B>()</CODE>
188
189 <BR>
190 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive double value.</TD>
191 </TR>
192 <TR BGCOLOR="white" CLASS="TableRowColor">
193 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
194 <CODE>&nbsp;float</CODE></FONT></TD>
195 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsFloat()">getAsFloat</A></B>()</CODE>
196
197 <BR>
198 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive float value.</TD>
199 </TR>
200 <TR BGCOLOR="white" CLASS="TableRowColor">
201 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
202 <CODE>&nbsp;int</CODE></FONT></TD>
203 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsInt()">getAsInt</A></B>()</CODE>
204
205 <BR>
206 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive integer value.</TD>
207 </TR>
208 <TR BGCOLOR="white" CLASS="TableRowColor">
209 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
210 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></CODE></FONT></TD>
211 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsJsonArray()">getAsJsonArray</A></B>()</CODE>
212
213 <BR>
214 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>.</TD>
215 </TR>
216 <TR BGCOLOR="white" CLASS="TableRowColor">
217 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
218 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></CODE></FONT></TD>
219 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsJsonNull()">getAsJsonNull</A></B>()</CODE>
220
221 <BR>
222 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.</TD>
223 </TR>
224 <TR BGCOLOR="white" CLASS="TableRowColor">
225 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
226 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></CODE></FONT></TD>
227 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsJsonObject()">getAsJsonObject</A></B>()</CODE>
228
229 <BR>
230 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.</TD>
231 </TR>
232 <TR BGCOLOR="white" CLASS="TableRowColor">
233 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
234 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></CODE></FONT></TD>
235 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsJsonPrimitive()">getAsJsonPrimitive</A></B>()</CODE>
236
237 <BR>
238 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.</TD>
239 </TR>
240 <TR BGCOLOR="white" CLASS="TableRowColor">
241 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
242 <CODE>&nbsp;long</CODE></FONT></TD>
243 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsLong()">getAsLong</A></B>()</CODE>
244
245 <BR>
246 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive long value.</TD>
247 </TR>
248 <TR BGCOLOR="white" CLASS="TableRowColor">
249 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
250 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A></CODE></FONT></TD>
251 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsNumber()">getAsNumber</A></B>()</CODE>
252
253 <BR>
254 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.</TD>
255 </TR>
256 <TR BGCOLOR="white" CLASS="TableRowColor">
257 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
258 <CODE>&nbsp;short</CODE></FONT></TD>
259 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsShort()">getAsShort</A></B>()</CODE>
260
261 <BR>
262 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive short value.</TD>
263 </TR>
264 <TR BGCOLOR="white" CLASS="TableRowColor">
265 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
266 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
267 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#getAsString()">getAsString</A></B>()</CODE>
268
269 <BR>
270 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a string value.</TD>
271 </TR>
272 <TR BGCOLOR="white" CLASS="TableRowColor">
273 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
274 <CODE>&nbsp;boolean</CODE></FONT></TD>
275 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#isJsonArray()">isJsonArray</A></B>()</CODE>
276
277 <BR>
278 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;provides check for verifying if this element is an array or not.</TD>
279 </TR>
280 <TR BGCOLOR="white" CLASS="TableRowColor">
281 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
282 <CODE>&nbsp;boolean</CODE></FONT></TD>
283 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#isJsonNull()">isJsonNull</A></B>()</CODE>
284
285 <BR>
286 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;provides check for verifying if this element represents a null value or not.</TD>
287 </TR>
288 <TR BGCOLOR="white" CLASS="TableRowColor">
289 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
290 <CODE>&nbsp;boolean</CODE></FONT></TD>
291 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#isJsonObject()">isJsonObject</A></B>()</CODE>
292
293 <BR>
294 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;provides check for verifying if this element is a Json object or not.</TD>
295 </TR>
296 <TR BGCOLOR="white" CLASS="TableRowColor">
297 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
298 <CODE>&nbsp;boolean</CODE></FONT></TD>
299 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#isJsonPrimitive()">isJsonPrimitive</A></B>()</CODE>
300
301 <BR>
302 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;provides check for verifying if this element is a primitive or not.</TD>
303 </TR>
304 <TR BGCOLOR="white" CLASS="TableRowColor">
305 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
306 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
307 <TD><CODE><B><A HREF="../../../com/google/gson/JsonElement.html#toString()">toString</A></B>()</CODE>
308
309 <BR>
310 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a String representation of this element.</TD>
311 </TR>
312 </TABLE>
313 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
314 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
315 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
316 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
317 </TR>
318 <TR BGCOLOR="white" CLASS="TableRowColor">
319 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
320 </TR>
321 </TABLE>
322 &nbsp;
323 <P>
324
325 <!-- ========= CONSTRUCTOR DETAIL ======== -->
326
327 <A NAME="constructor_detail"><!-- --></A>
328 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
329 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
330 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
331 <B>Constructor Detail</B></FONT></TH>
332 </TR>
333 </TABLE>
334
335 <A NAME="JsonElement()"><!-- --></A><H3>
336 JsonElement</H3>
337 <PRE>
338 public <B>JsonElement</B>()</PRE>
339 <DL>
340 </DL>
341
342 <!-- ============ METHOD DETAIL ========== -->
343
344 <A NAME="method_detail"><!-- --></A>
345 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
346 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
347 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
348 <B>Method Detail</B></FONT></TH>
349 </TR>
350 </TABLE>
351
352 <A NAME="isJsonArray()"><!-- --></A><H3>
353 isJsonArray</H3>
354 <PRE>
355 public boolean <B>isJsonArray</B>()</PRE>
356 <DL>
357 <DD>provides check for verifying if this element is an array or not.
358 <P>
359 <DD><DL>
360
361 <DT><B>Returns:</B><DD>true if this element is of type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>, false otherwise.</DL>
362 </DD>
363 </DL>
364 <HR>
365
366 <A NAME="isJsonObject()"><!-- --></A><H3>
367 isJsonObject</H3>
368 <PRE>
369 public boolean <B>isJsonObject</B>()</PRE>
370 <DL>
371 <DD>provides check for verifying if this element is a Json object or not.
372 <P>
373 <DD><DL>
374
375 <DT><B>Returns:</B><DD>true if this element is of type <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>, false otherwise.</DL>
376 </DD>
377 </DL>
378 <HR>
379
380 <A NAME="isJsonPrimitive()"><!-- --></A><H3>
381 isJsonPrimitive</H3>
382 <PRE>
383 public boolean <B>isJsonPrimitive</B>()</PRE>
384 <DL>
385 <DD>provides check for verifying if this element is a primitive or not.
386 <P>
387 <DD><DL>
388
389 <DT><B>Returns:</B><DD>true if this element is of type <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>, false otherwise.</DL>
390 </DD>
391 </DL>
392 <HR>
393
394 <A NAME="isJsonNull()"><!-- --></A><H3>
395 isJsonNull</H3>
396 <PRE>
397 public boolean <B>isJsonNull</B>()</PRE>
398 <DL>
399 <DD>provides check for verifying if this element represents a null value or not.
400 <P>
401 <DD><DL>
402
403 <DT><B>Returns:</B><DD>true if this element is of type <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>, false otherwise.<DT><B>Since:</B></DT>
404 <DD>1.2</DD>
405 </DL>
406 </DD>
407 </DL>
408 <HR>
409
410 <A NAME="getAsJsonObject()"><!-- --></A><H3>
411 getAsJsonObject</H3>
412 <PRE>
413 public <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A> <B>getAsJsonObject</B>()</PRE>
414 <DL>
415 <DD>convenience method to get this element as a <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>. If the element is of some
416 other type, a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalStateException</CODE></A> will result. Hence it is best to use this method
417 after ensuring that this element is of the desired type by calling <A HREF="../../../com/google/gson/JsonElement.html#isJsonObject()"><CODE>isJsonObject()</CODE></A>
418 first.
419 <P>
420 <DD><DL>
421
422 <DT><B>Returns:</B><DD>get this element as a <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.
423 <DT><B>Throws:</B>
424 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of another type.</DL>
425 </DD>
426 </DL>
427 <HR>
428
429 <A NAME="getAsJsonArray()"><!-- --></A><H3>
430 getAsJsonArray</H3>
431 <PRE>
432 public <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A> <B>getAsJsonArray</B>()</PRE>
433 <DL>
434 <DD>convenience method to get this element as a <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>. If the element is of some
435 other type, a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalStateException</CODE></A> will result. Hence it is best to use this method
436 after ensuring that this element is of the desired type by calling <A HREF="../../../com/google/gson/JsonElement.html#isJsonArray()"><CODE>isJsonArray()</CODE></A>
437 first.
438 <P>
439 <DD><DL>
440
441 <DT><B>Returns:</B><DD>get this element as a <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>.
442 <DT><B>Throws:</B>
443 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of another type.</DL>
444 </DD>
445 </DL>
446 <HR>
447
448 <A NAME="getAsJsonPrimitive()"><!-- --></A><H3>
449 getAsJsonPrimitive</H3>
450 <PRE>
451 public <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A> <B>getAsJsonPrimitive</B>()</PRE>
452 <DL>
453 <DD>convenience method to get this element as a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>. If the element is of some
454 other type, a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalStateException</CODE></A> will result. Hence it is best to use this method
455 after ensuring that this element is of the desired type by calling <A HREF="../../../com/google/gson/JsonElement.html#isJsonPrimitive()"><CODE>isJsonPrimitive()</CODE></A>
456 first.
457 <P>
458 <DD><DL>
459
460 <DT><B>Returns:</B><DD>get this element as a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.
461 <DT><B>Throws:</B>
462 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of another type.</DL>
463 </DD>
464 </DL>
465 <HR>
466
467 <A NAME="getAsJsonNull()"><!-- --></A><H3>
468 getAsJsonNull</H3>
469 <PRE>
470 public <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A> <B>getAsJsonNull</B>()</PRE>
471 <DL>
472 <DD>convenience method to get this element as a <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>. If the element is of some
473 other type, a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalStateException</CODE></A> will result. Hence it is best to use this method
474 after ensuring that this element is of the desired type by calling <A HREF="../../../com/google/gson/JsonElement.html#isJsonNull()"><CODE>isJsonNull()</CODE></A>
475 first.
476 <P>
477 <DD><DL>
478
479 <DT><B>Returns:</B><DD>get this element as a <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.
480 <DT><B>Throws:</B>
481 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of another type.<DT><B>Since:</B></DT>
482 <DD>1.2</DD>
483 </DL>
484 </DD>
485 </DL>
486 <HR>
487
488 <A NAME="getAsBoolean()"><!-- --></A><H3>
489 getAsBoolean</H3>
490 <PRE>
491 public boolean <B>getAsBoolean</B>()</PRE>
492 <DL>
493 <DD>convenience method to get this element as a boolean value.
494 <P>
495 <DD><DL>
496
497 <DT><B>Returns:</B><DD>get this element as a primitive boolean value.
498 <DT><B>Throws:</B>
499 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
500 boolean value.
501 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
502 more than a single element.</DL>
503 </DD>
504 </DL>
505 <HR>
506
507 <A NAME="getAsNumber()"><!-- --></A><H3>
508 getAsNumber</H3>
509 <PRE>
510 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A> <B>getAsNumber</B>()</PRE>
511 <DL>
512 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.
513 <P>
514 <DD><DL>
515
516 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.
517 <DT><B>Throws:</B>
518 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
519 number.
520 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
521 more than a single element.</DL>
522 </DD>
523 </DL>
524 <HR>
525
526 <A NAME="getAsString()"><!-- --></A><H3>
527 getAsString</H3>
528 <PRE>
529 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getAsString</B>()</PRE>
530 <DL>
531 <DD>convenience method to get this element as a string value.
532 <P>
533 <DD><DL>
534
535 <DT><B>Returns:</B><DD>get this element as a string value.
536 <DT><B>Throws:</B>
537 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
538 string value.
539 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
540 more than a single element.</DL>
541 </DD>
542 </DL>
543 <HR>
544
545 <A NAME="getAsDouble()"><!-- --></A><H3>
546 getAsDouble</H3>
547 <PRE>
548 public double <B>getAsDouble</B>()</PRE>
549 <DL>
550 <DD>convenience method to get this element as a primitive double value.
551 <P>
552 <DD><DL>
553
554 <DT><B>Returns:</B><DD>get this element as a primitive double value.
555 <DT><B>Throws:</B>
556 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
557 double value.
558 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
559 more than a single element.</DL>
560 </DD>
561 </DL>
562 <HR>
563
564 <A NAME="getAsFloat()"><!-- --></A><H3>
565 getAsFloat</H3>
566 <PRE>
567 public float <B>getAsFloat</B>()</PRE>
568 <DL>
569 <DD>convenience method to get this element as a primitive float value.
570 <P>
571 <DD><DL>
572
573 <DT><B>Returns:</B><DD>get this element as a primitive float value.
574 <DT><B>Throws:</B>
575 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
576 float value.
577 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
578 more than a single element.</DL>
579 </DD>
580 </DL>
581 <HR>
582
583 <A NAME="getAsLong()"><!-- --></A><H3>
584 getAsLong</H3>
585 <PRE>
586 public long <B>getAsLong</B>()</PRE>
587 <DL>
588 <DD>convenience method to get this element as a primitive long value.
589 <P>
590 <DD><DL>
591
592 <DT><B>Returns:</B><DD>get this element as a primitive long value.
593 <DT><B>Throws:</B>
594 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
595 long value.
596 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
597 more than a single element.</DL>
598 </DD>
599 </DL>
600 <HR>
601
602 <A NAME="getAsInt()"><!-- --></A><H3>
603 getAsInt</H3>
604 <PRE>
605 public int <B>getAsInt</B>()</PRE>
606 <DL>
607 <DD>convenience method to get this element as a primitive integer value.
608 <P>
609 <DD><DL>
610
611 <DT><B>Returns:</B><DD>get this element as a primitive integer value.
612 <DT><B>Throws:</B>
613 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
614 integer value.
615 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
616 more than a single element.</DL>
617 </DD>
618 </DL>
619 <HR>
620
621 <A NAME="getAsByte()"><!-- --></A><H3>
622 getAsByte</H3>
623 <PRE>
624 public byte <B>getAsByte</B>()</PRE>
625 <DL>
626 <DD>convenience method to get this element as a primitive byte value.
627 <P>
628 <DD><DL>
629
630 <DT><B>Returns:</B><DD>get this element as a primitive byte value.
631 <DT><B>Throws:</B>
632 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
633 byte value.
634 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
635 more than a single element.<DT><B>Since:</B></DT>
636 <DD>1.3</DD>
637 </DL>
638 </DD>
639 </DL>
640 <HR>
641
642 <A NAME="getAsCharacter()"><!-- --></A><H3>
643 getAsCharacter</H3>
644 <PRE>
645 public char <B>getAsCharacter</B>()</PRE>
646 <DL>
647 <DD>convenience method to get this element as a primitive character value.
648 <P>
649 <DD><DL>
650
651 <DT><B>Returns:</B><DD>get this element as a primitive char value.
652 <DT><B>Throws:</B>
653 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
654 char value.
655 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
656 more than a single element.<DT><B>Since:</B></DT>
657 <DD>1.3</DD>
658 </DL>
659 </DD>
660 </DL>
661 <HR>
662
663 <A NAME="getAsBigDecimal()"><!-- --></A><H3>
664 getAsBigDecimal</H3>
665 <PRE>
666 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math">BigDecimal</A> <B>getAsBigDecimal</B>()</PRE>
667 <DL>
668 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
669 <P>
670 <DD><DL>
671
672 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
673 <DT><B>Throws:</B>
674 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.
675 * @throws NumberFormatException if the element is not a valid <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
676 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
677 more than a single element.<DT><B>Since:</B></DT>
678 <DD>1.2</DD>
679 </DL>
680 </DD>
681 </DL>
682 <HR>
683
684 <A NAME="getAsBigInteger()"><!-- --></A><H3>
685 getAsBigInteger</H3>
686 <PRE>
687 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</A> <B>getAsBigInteger</B>()</PRE>
688 <DL>
689 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
690 <P>
691 <DD><DL>
692
693 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
694 <DT><B>Throws:</B>
695 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.
696 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the element is not a valid <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
697 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
698 more than a single element.<DT><B>Since:</B></DT>
699 <DD>1.2</DD>
700 </DL>
701 </DD>
702 </DL>
703 <HR>
704
705 <A NAME="getAsShort()"><!-- --></A><H3>
706 getAsShort</H3>
707 <PRE>
708 public short <B>getAsShort</B>()</PRE>
709 <DL>
710 <DD>convenience method to get this element as a primitive short value.
711 <P>
712 <DD><DL>
713
714 <DT><B>Returns:</B><DD>get this element as a primitive short value.
715 <DT><B>Throws:</B>
716 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/ClassCastException.html?is-external=true" title="class or interface in java.lang">ClassCastException</A></CODE> - if the element is of not a <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A> and is not a valid
717 short value.
718 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the element is of the type <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A> but contains
719 more than a single element.</DL>
720 </DD>
721 </DL>
722 <HR>
723
724 <A NAME="toString()"><!-- --></A><H3>
725 toString</H3>
726 <PRE>
727 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toString</B>()</PRE>
728 <DL>
729 <DD>Returns a String representation of this element.
730 <P>
731 <DD><DL>
732 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
733 </DD>
734 <DD><DL>
735 </DL>
736 </DD>
737 </DL>
738 <!-- ========= END OF CLASS DATA ========= -->
739 <HR>
740
741
742 <!-- ======= START OF BOTTOM NAVBAR ====== -->
743 <A NAME="navbar_bottom"><!-- --></A>
744 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
745 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
746 <TR>
747 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
748 <A NAME="navbar_bottom_firstrow"><!-- --></A>
749 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
750 <TR ALIGN="center" VALIGN="top">
751 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
752 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
753 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
754 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonElement.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
755 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
756 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
757 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
758 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
759 </TR>
760 </TABLE>
761 </TD>
762 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
763 </EM>
764 </TD>
765 </TR>
766
767 <TR>
768 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
769 &nbsp;<A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
770 &nbsp;<A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
771 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
772 <A HREF="../../../index.html?com/google/gson/JsonElement.html" target="_top"><B>FRAMES</B></A> &nbsp;
773 &nbsp;<A HREF="JsonElement.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
774 &nbsp;<SCRIPT type="text/javascript">
775 <!--
776 if(window==top) {
777 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
778 }
779 //-->
780 </SCRIPT>
781 <NOSCRIPT>
782 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
783 </NOSCRIPT>
784
785
786 </FONT></TD>
787 </TR>
788 <TR>
789 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
790 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
791 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
792 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
793 </TR>
794 </TABLE>
795 <A NAME="skip-navbar_bottom"></A>
796 <!-- ======== END OF BOTTOM NAVBAR ======= -->
797
798 <HR>
799 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
800 </BODY>
801 </HTML>
+0
-285
gson/docs/javadocs/com/google/gson/JsonIOException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonIOException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonIOException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonIOException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonIOException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonIOException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonIOException</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">java.lang.Throwable</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">java.lang.Exception</A>
98 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang">java.lang.RuntimeException</A>
99 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">com.google.gson.JsonParseException</A>
100 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonIOException</B>
101 </PRE>
102 <DL>
103 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A></DD>
104 </DL>
105 <HR>
106 <DL>
107 <DT><PRE>public final class <B>JsonIOException</B><DT>extends <A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></DL>
108 </PRE>
109
110 <P>
111 This exception is raised when Gson was unable to read an input stream
112 or write to one.
113 <P>
114
115 <P>
116 <DL>
117 <DT><B>Author:</B></DT>
118 <DD>Inderjeet Singh, Joel Leitch</DD>
119 <DT><B>See Also:</B><DD><A HREF="../../../serialized-form.html#com.google.gson.JsonIOException">Serialized Form</A></DL>
120 <HR>
121
122 <P>
123
124 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
125
126 <A NAME="constructor_summary"><!-- --></A>
127 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
128 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
129 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
130 <B>Constructor Summary</B></FONT></TH>
131 </TR>
132 <TR BGCOLOR="white" CLASS="TableRowColor">
133 <TD><CODE><B><A HREF="../../../com/google/gson/JsonIOException.html#JsonIOException(java.lang.String)">JsonIOException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
137 </TR>
138 <TR BGCOLOR="white" CLASS="TableRowColor">
139 <TD><CODE><B><A HREF="../../../com/google/gson/JsonIOException.html#JsonIOException(java.lang.String, java.lang.Throwable)">JsonIOException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
140 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</CODE>
141
142 <BR>
143 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
144 </TR>
145 <TR BGCOLOR="white" CLASS="TableRowColor">
146 <TD><CODE><B><A HREF="../../../com/google/gson/JsonIOException.html#JsonIOException(java.lang.Throwable)">JsonIOException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</CODE>
147
148 <BR>
149 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates exception with the specified cause.</TD>
150 </TR>
151 </TABLE>
152 &nbsp;
153 <!-- ========== METHOD SUMMARY =========== -->
154
155 <A NAME="method_summary"><!-- --></A>
156 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
157 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
158 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
159 <B>Method Summary</B></FONT></TH>
160 </TR>
161 </TABLE>
162 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Throwable"><!-- --></A>
163 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
164 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
165 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A></B></TH>
166 </TR>
167 <TR BGCOLOR="white" CLASS="TableRowColor">
168 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#fillInStackTrace()" title="class or interface in java.lang">fillInStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getCause()" title="class or interface in java.lang">getCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getLocalizedMessage()" title="class or interface in java.lang">getLocalizedMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getMessage()" title="class or interface in java.lang">getMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getStackTrace()" title="class or interface in java.lang">getStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#initCause(java.lang.Throwable)" title="class or interface in java.lang">initCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace()" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintStream)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintWriter)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#setStackTrace(java.lang.StackTraceElement[])" title="class or interface in java.lang">setStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE></TD>
169 </TR>
170 </TABLE>
171 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
172 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
173 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
174 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
175 </TR>
176 <TR BGCOLOR="white" CLASS="TableRowColor">
177 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
178 </TR>
179 </TABLE>
180 &nbsp;
181 <P>
182
183 <!-- ========= CONSTRUCTOR DETAIL ======== -->
184
185 <A NAME="constructor_detail"><!-- --></A>
186 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
187 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
188 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
189 <B>Constructor Detail</B></FONT></TH>
190 </TR>
191 </TABLE>
192
193 <A NAME="JsonIOException(java.lang.String)"><!-- --></A><H3>
194 JsonIOException</H3>
195 <PRE>
196 public <B>JsonIOException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</PRE>
197 <DL>
198 </DL>
199 <HR>
200
201 <A NAME="JsonIOException(java.lang.String, java.lang.Throwable)"><!-- --></A><H3>
202 JsonIOException</H3>
203 <PRE>
204 public <B>JsonIOException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
205 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</PRE>
206 <DL>
207 </DL>
208 <HR>
209
210 <A NAME="JsonIOException(java.lang.Throwable)"><!-- --></A><H3>
211 JsonIOException</H3>
212 <PRE>
213 public <B>JsonIOException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</PRE>
214 <DL>
215 <DD>Creates exception with the specified cause. Consider using
216 <A HREF="../../../com/google/gson/JsonIOException.html#JsonIOException(java.lang.String, java.lang.Throwable)"><CODE>JsonIOException(String, Throwable)</CODE></A> instead if you can describe what happened.
217 <P>
218 <DL>
219 <DT><B>Parameters:</B><DD><CODE>cause</CODE> - root exception that caused this exception to be thrown.</DL>
220 </DL>
221 <!-- ========= END OF CLASS DATA ========= -->
222 <HR>
223
224
225 <!-- ======= START OF BOTTOM NAVBAR ====== -->
226 <A NAME="navbar_bottom"><!-- --></A>
227 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
228 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
229 <TR>
230 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
231 <A NAME="navbar_bottom_firstrow"><!-- --></A>
232 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
233 <TR ALIGN="center" VALIGN="top">
234 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
235 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
236 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
237 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonIOException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
238 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
239 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
240 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
241 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
242 </TR>
243 </TABLE>
244 </TD>
245 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
246 </EM>
247 </TD>
248 </TR>
249
250 <TR>
251 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
252 &nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
253 &nbsp;<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
254 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
255 <A HREF="../../../index.html?com/google/gson/JsonIOException.html" target="_top"><B>FRAMES</B></A> &nbsp;
256 &nbsp;<A HREF="JsonIOException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
257 &nbsp;<SCRIPT type="text/javascript">
258 <!--
259 if(window==top) {
260 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
261 }
262 //-->
263 </SCRIPT>
264 <NOSCRIPT>
265 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
266 </NOSCRIPT>
267
268
269 </FONT></TD>
270 </TR>
271 <TR>
272 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
273 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
274 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
275 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
276 </TR>
277 </TABLE>
278 <A NAME="skip-navbar_bottom"></A>
279 <!-- ======== END OF BOTTOM NAVBAR ======= -->
280
281 <HR>
282 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
283 </BODY>
284 </HTML>
+0
-348
gson/docs/javadocs/com/google/gson/JsonNull.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonNull (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonNull (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonNull.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonNull.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonNull.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonNull</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">com.google.gson.JsonElement</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonNull</B>
98 </PRE>
99 <HR>
100 <DL>
101 <DT><PRE>public final class <B>JsonNull</B><DT>extends <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></DL>
102 </PRE>
103
104 <P>
105 A class representing a Json <code>null</code> value.
106 <P>
107
108 <P>
109 <DL>
110 <DT><B>Since:</B></DT>
111 <DD>1.2</DD>
112 <DT><B>Author:</B></DT>
113 <DD>Inderjeet Singh, Joel Leitch</DD>
114 </DL>
115 <HR>
116
117 <P>
118 <!-- =========== FIELD SUMMARY =========== -->
119
120 <A NAME="field_summary"><!-- --></A>
121 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
122 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
123 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
124 <B>Field Summary</B></FONT></TH>
125 </TR>
126 <TR BGCOLOR="white" CLASS="TableRowColor">
127 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
128 <CODE>static&nbsp;<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></CODE></FONT></TD>
129 <TD><CODE><B><A HREF="../../../com/google/gson/JsonNull.html#INSTANCE">INSTANCE</A></B></CODE>
130
131 <BR>
132 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;singleton for JsonNull</TD>
133 </TR>
134 </TABLE>
135 &nbsp;
136 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
137
138 <A NAME="constructor_summary"><!-- --></A>
139 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
140 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
141 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
142 <B>Constructor Summary</B></FONT></TH>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD><CODE><B><A HREF="../../../com/google/gson/JsonNull.html#JsonNull()">JsonNull</A></B>()</CODE>
146
147 <BR>
148 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;</TD>
149 </TR>
150 </TABLE>
151 &nbsp;
152 <!-- ========== METHOD SUMMARY =========== -->
153
154 <A NAME="method_summary"><!-- --></A>
155 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
156 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
157 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
158 <B>Method Summary</B></FONT></TH>
159 </TR>
160 <TR BGCOLOR="white" CLASS="TableRowColor">
161 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
162 <CODE>&nbsp;boolean</CODE></FONT></TD>
163 <TD><CODE><B><A HREF="../../../com/google/gson/JsonNull.html#equals(java.lang.Object)">equals</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;other)</CODE>
164
165 <BR>
166 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;All instances of JsonNull are the same</TD>
167 </TR>
168 <TR BGCOLOR="white" CLASS="TableRowColor">
169 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
170 <CODE>&nbsp;int</CODE></FONT></TD>
171 <TD><CODE><B><A HREF="../../../com/google/gson/JsonNull.html#hashCode()">hashCode</A></B>()</CODE>
172
173 <BR>
174 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;All instances of JsonNull have the same hash code since they are indistinguishable</TD>
175 </TR>
176 </TABLE>
177 &nbsp;<A NAME="methods_inherited_from_class_com.google.gson.JsonElement"><!-- --></A>
178 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
179 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
180 <TH ALIGN="left"><B>Methods inherited from class com.google.gson.<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></B></TH>
181 </TR>
182 <TR BGCOLOR="white" CLASS="TableRowColor">
183 <TD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBigDecimal()">getAsBigDecimal</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsBigInteger()">getAsBigInteger</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsBoolean()">getAsBoolean</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">getAsByte</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">getAsCharacter</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsDouble()">getAsDouble</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsFloat()">getAsFloat</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsInt()">getAsInt</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonArray()">getAsJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonNull()">getAsJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonObject()">getAsJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonPrimitive()">getAsJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsLong()">getAsLong</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsNumber()">getAsNumber</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsShort()">getAsShort</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsString()">getAsString</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonArray()">isJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonNull()">isJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonObject()">isJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonPrimitive()">isJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#toString()">toString</A></CODE></TD>
184 </TR>
185 </TABLE>
186 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
187 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
188 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
189 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
190 </TR>
191 <TR BGCOLOR="white" CLASS="TableRowColor">
192 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
193 </TR>
194 </TABLE>
195 &nbsp;
196 <P>
197
198 <!-- ============ FIELD DETAIL =========== -->
199
200 <A NAME="field_detail"><!-- --></A>
201 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
202 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
203 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
204 <B>Field Detail</B></FONT></TH>
205 </TR>
206 </TABLE>
207
208 <A NAME="INSTANCE"><!-- --></A><H3>
209 INSTANCE</H3>
210 <PRE>
211 public static final <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A> <B>INSTANCE</B></PRE>
212 <DL>
213 <DD>singleton for JsonNull
214 <P>
215 <DL>
216 <DT><B>Since:</B></DT>
217 <DD>1.8</DD>
218 </DL>
219 </DL>
220
221 <!-- ========= CONSTRUCTOR DETAIL ======== -->
222
223 <A NAME="constructor_detail"><!-- --></A>
224 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
225 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
226 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
227 <B>Constructor Detail</B></FONT></TH>
228 </TR>
229 </TABLE>
230
231 <A NAME="JsonNull()"><!-- --></A><H3>
232 JsonNull</H3>
233 <PRE>
234 <FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</A>
235 </FONT>public <B>JsonNull</B>()</PRE>
236 <DL>
237 <DD><B>Deprecated.</B>&nbsp;
238 <P>
239 <DD>Creates a new JsonNull object.
240 Deprecated since Gson version 1.8. Use <A HREF="../../../com/google/gson/JsonNull.html#INSTANCE"><CODE>INSTANCE</CODE></A> instead
241 <P>
242 </DL>
243
244 <!-- ============ METHOD DETAIL ========== -->
245
246 <A NAME="method_detail"><!-- --></A>
247 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
248 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
249 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
250 <B>Method Detail</B></FONT></TH>
251 </TR>
252 </TABLE>
253
254 <A NAME="hashCode()"><!-- --></A><H3>
255 hashCode</H3>
256 <PRE>
257 public int <B>hashCode</B>()</PRE>
258 <DL>
259 <DD>All instances of JsonNull have the same hash code since they are indistinguishable
260 <P>
261 <DD><DL>
262 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
263 </DD>
264 <DD><DL>
265 </DL>
266 </DD>
267 </DL>
268 <HR>
269
270 <A NAME="equals(java.lang.Object)"><!-- --></A><H3>
271 equals</H3>
272 <PRE>
273 public boolean <B>equals</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;other)</PRE>
274 <DL>
275 <DD>All instances of JsonNull are the same
276 <P>
277 <DD><DL>
278 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
279 </DD>
280 <DD><DL>
281 </DL>
282 </DD>
283 </DL>
284 <!-- ========= END OF CLASS DATA ========= -->
285 <HR>
286
287
288 <!-- ======= START OF BOTTOM NAVBAR ====== -->
289 <A NAME="navbar_bottom"><!-- --></A>
290 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
291 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
292 <TR>
293 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
294 <A NAME="navbar_bottom_firstrow"><!-- --></A>
295 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
296 <TR ALIGN="center" VALIGN="top">
297 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
298 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
299 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
300 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonNull.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
301 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
302 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
303 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
304 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
305 </TR>
306 </TABLE>
307 </TD>
308 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
309 </EM>
310 </TD>
311 </TR>
312
313 <TR>
314 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
315 &nbsp;<A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
316 &nbsp;<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
317 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
318 <A HREF="../../../index.html?com/google/gson/JsonNull.html" target="_top"><B>FRAMES</B></A> &nbsp;
319 &nbsp;<A HREF="JsonNull.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
320 &nbsp;<SCRIPT type="text/javascript">
321 <!--
322 if(window==top) {
323 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
324 }
325 //-->
326 </SCRIPT>
327 <NOSCRIPT>
328 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
329 </NOSCRIPT>
330
331
332 </FONT></TD>
333 </TR>
334 <TR>
335 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
336 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
337 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
338 DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
339 </TR>
340 </TABLE>
341 <A NAME="skip-navbar_bottom"></A>
342 <!-- ======== END OF BOTTOM NAVBAR ======= -->
343
344 <HR>
345 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
346 </BODY>
347 </HTML>
+0
-576
gson/docs/javadocs/com/google/gson/JsonObject.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonObject (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonObject (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonObject.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonObject.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonObject.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonObject</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">com.google.gson.JsonElement</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonObject</B>
98 </PRE>
99 <HR>
100 <DL>
101 <DT><PRE>public final class <B>JsonObject</B><DT>extends <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></DL>
102 </PRE>
103
104 <P>
105 A class representing an object type in Json. An object consists of name-value pairs where names
106 are strings, and values are any other type of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>. This allows for a creating a
107 tree of JsonElements. The member elements of this object are maintained in order they were added.
108 <P>
109
110 <P>
111 <DL>
112 <DT><B>Author:</B></DT>
113 <DD>Inderjeet Singh, Joel Leitch</DD>
114 </DL>
115 <HR>
116
117 <P>
118
119 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
120
121 <A NAME="constructor_summary"><!-- --></A>
122 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
123 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
124 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
125 <B>Constructor Summary</B></FONT></TH>
126 </TR>
127 <TR BGCOLOR="white" CLASS="TableRowColor">
128 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#JsonObject()">JsonObject</A></B>()</CODE>
129
130 <BR>
131 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
132 </TR>
133 </TABLE>
134 &nbsp;
135 <!-- ========== METHOD SUMMARY =========== -->
136
137 <A NAME="method_summary"><!-- --></A>
138 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
139 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
140 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
141 <B>Method Summary</B></FONT></TH>
142 </TR>
143 <TR BGCOLOR="white" CLASS="TableRowColor">
144 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
145 <CODE>&nbsp;void</CODE></FONT></TD>
146 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#add(java.lang.String, com.google.gson.JsonElement)">add</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
147 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;value)</CODE>
148
149 <BR>
150 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a member, which is a name-value pair, to self.</TD>
151 </TR>
152 <TR BGCOLOR="white" CLASS="TableRowColor">
153 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
154 <CODE>&nbsp;void</CODE></FONT></TD>
155 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.Boolean)">addProperty</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
156 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</A>&nbsp;value)</CODE>
157
158 <BR>
159 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to add a boolean member.</TD>
160 </TR>
161 <TR BGCOLOR="white" CLASS="TableRowColor">
162 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
163 <CODE>&nbsp;void</CODE></FONT></TD>
164 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.Character)">addProperty</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
165 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Character.html?is-external=true" title="class or interface in java.lang">Character</A>&nbsp;value)</CODE>
166
167 <BR>
168 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to add a char member.</TD>
169 </TR>
170 <TR BGCOLOR="white" CLASS="TableRowColor">
171 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
172 <CODE>&nbsp;void</CODE></FONT></TD>
173 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.Number)">addProperty</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
174 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;value)</CODE>
175
176 <BR>
177 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to add a primitive member.</TD>
178 </TR>
179 <TR BGCOLOR="white" CLASS="TableRowColor">
180 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
181 <CODE>&nbsp;void</CODE></FONT></TD>
182 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.String)">addProperty</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
183 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;value)</CODE>
184
185 <BR>
186 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to add a primitive member.</TD>
187 </TR>
188 <TR BGCOLOR="white" CLASS="TableRowColor">
189 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
190 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Map.Entry.html?is-external=true" title="class or interface in java.util">Map.Entry</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;&gt;</CODE></FONT></TD>
191 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#entrySet()">entrySet</A></B>()</CODE>
192
193 <BR>
194 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a set of members of this object.</TD>
195 </TR>
196 <TR BGCOLOR="white" CLASS="TableRowColor">
197 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
198 <CODE>&nbsp;boolean</CODE></FONT></TD>
199 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#equals(java.lang.Object)">equals</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;o)</CODE>
200
201 <BR>
202 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
203 </TR>
204 <TR BGCOLOR="white" CLASS="TableRowColor">
205 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
206 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
207 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#get(java.lang.String)">get</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
208
209 <BR>
210 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the member with the specified name.</TD>
211 </TR>
212 <TR BGCOLOR="white" CLASS="TableRowColor">
213 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
214 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></CODE></FONT></TD>
215 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#getAsJsonArray(java.lang.String)">getAsJsonArray</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
216
217 <BR>
218 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to get the specified member as a JsonArray.</TD>
219 </TR>
220 <TR BGCOLOR="white" CLASS="TableRowColor">
221 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
222 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></CODE></FONT></TD>
223 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#getAsJsonObject(java.lang.String)">getAsJsonObject</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
224
225 <BR>
226 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to get the specified member as a JsonObject.</TD>
227 </TR>
228 <TR BGCOLOR="white" CLASS="TableRowColor">
229 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
230 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></CODE></FONT></TD>
231 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#getAsJsonPrimitive(java.lang.String)">getAsJsonPrimitive</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
232
233 <BR>
234 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to get the specified member as a JsonPrimitive element.</TD>
235 </TR>
236 <TR BGCOLOR="white" CLASS="TableRowColor">
237 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
238 <CODE>&nbsp;boolean</CODE></FONT></TD>
239 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#has(java.lang.String)">has</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
240
241 <BR>
242 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to check if a member with the specified name is present in this object.</TD>
243 </TR>
244 <TR BGCOLOR="white" CLASS="TableRowColor">
245 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
246 <CODE>&nbsp;int</CODE></FONT></TD>
247 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#hashCode()">hashCode</A></B>()</CODE>
248
249 <BR>
250 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
251 </TR>
252 <TR BGCOLOR="white" CLASS="TableRowColor">
253 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
254 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
255 <TD><CODE><B><A HREF="../../../com/google/gson/JsonObject.html#remove(java.lang.String)">remove</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property)</CODE>
256
257 <BR>
258 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the <code>property</code> from this <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.</TD>
259 </TR>
260 </TABLE>
261 &nbsp;<A NAME="methods_inherited_from_class_com.google.gson.JsonElement"><!-- --></A>
262 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
263 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
264 <TH ALIGN="left"><B>Methods inherited from class com.google.gson.<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></B></TH>
265 </TR>
266 <TR BGCOLOR="white" CLASS="TableRowColor">
267 <TD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBigDecimal()">getAsBigDecimal</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsBigInteger()">getAsBigInteger</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsBoolean()">getAsBoolean</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">getAsByte</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">getAsCharacter</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsDouble()">getAsDouble</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsFloat()">getAsFloat</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsInt()">getAsInt</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonArray()">getAsJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonNull()">getAsJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonObject()">getAsJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonPrimitive()">getAsJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsLong()">getAsLong</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsNumber()">getAsNumber</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsShort()">getAsShort</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsString()">getAsString</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonArray()">isJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonNull()">isJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonObject()">isJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonPrimitive()">isJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#toString()">toString</A></CODE></TD>
268 </TR>
269 </TABLE>
270 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
271 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
272 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
273 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
274 </TR>
275 <TR BGCOLOR="white" CLASS="TableRowColor">
276 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
277 </TR>
278 </TABLE>
279 &nbsp;
280 <P>
281
282 <!-- ========= CONSTRUCTOR DETAIL ======== -->
283
284 <A NAME="constructor_detail"><!-- --></A>
285 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
286 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
287 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
288 <B>Constructor Detail</B></FONT></TH>
289 </TR>
290 </TABLE>
291
292 <A NAME="JsonObject()"><!-- --></A><H3>
293 JsonObject</H3>
294 <PRE>
295 public <B>JsonObject</B>()</PRE>
296 <DL>
297 </DL>
298
299 <!-- ============ METHOD DETAIL ========== -->
300
301 <A NAME="method_detail"><!-- --></A>
302 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
303 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
304 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
305 <B>Method Detail</B></FONT></TH>
306 </TR>
307 </TABLE>
308
309 <A NAME="add(java.lang.String, com.google.gson.JsonElement)"><!-- --></A><H3>
310 add</H3>
311 <PRE>
312 public void <B>add</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
313 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;value)</PRE>
314 <DL>
315 <DD>Adds a member, which is a name-value pair, to self. The name must be a String, but the value
316 can be an arbitrary JsonElement, thereby allowing you to build a full tree of JsonElements
317 rooted at this node.
318 <P>
319 <DD><DL>
320 <DT><B>Parameters:</B><DD><CODE>property</CODE> - name of the member.<DD><CODE>value</CODE> - the member object.</DL>
321 </DD>
322 </DL>
323 <HR>
324
325 <A NAME="remove(java.lang.String)"><!-- --></A><H3>
326 remove</H3>
327 <PRE>
328 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>remove</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property)</PRE>
329 <DL>
330 <DD>Removes the <code>property</code> from this <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.
331 <P>
332 <DD><DL>
333 <DT><B>Parameters:</B><DD><CODE>property</CODE> - name of the member that should be removed.
334 <DT><B>Returns:</B><DD>the <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> object that is being removed.<DT><B>Since:</B></DT>
335 <DD>1.3</DD>
336 </DL>
337 </DD>
338 </DL>
339 <HR>
340
341 <A NAME="addProperty(java.lang.String, java.lang.String)"><!-- --></A><H3>
342 addProperty</H3>
343 <PRE>
344 public void <B>addProperty</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
345 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;value)</PRE>
346 <DL>
347 <DD>Convenience method to add a primitive member. The specified value is converted to a
348 JsonPrimitive of String.
349 <P>
350 <DD><DL>
351 <DT><B>Parameters:</B><DD><CODE>property</CODE> - name of the member.<DD><CODE>value</CODE> - the string value associated with the member.</DL>
352 </DD>
353 </DL>
354 <HR>
355
356 <A NAME="addProperty(java.lang.String, java.lang.Number)"><!-- --></A><H3>
357 addProperty</H3>
358 <PRE>
359 public void <B>addProperty</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
360 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;value)</PRE>
361 <DL>
362 <DD>Convenience method to add a primitive member. The specified value is converted to a
363 JsonPrimitive of Number.
364 <P>
365 <DD><DL>
366 <DT><B>Parameters:</B><DD><CODE>property</CODE> - name of the member.<DD><CODE>value</CODE> - the number value associated with the member.</DL>
367 </DD>
368 </DL>
369 <HR>
370
371 <A NAME="addProperty(java.lang.String, java.lang.Boolean)"><!-- --></A><H3>
372 addProperty</H3>
373 <PRE>
374 public void <B>addProperty</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
375 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</A>&nbsp;value)</PRE>
376 <DL>
377 <DD>Convenience method to add a boolean member. The specified value is converted to a
378 JsonPrimitive of Boolean.
379 <P>
380 <DD><DL>
381 <DT><B>Parameters:</B><DD><CODE>property</CODE> - name of the member.<DD><CODE>value</CODE> - the number value associated with the member.</DL>
382 </DD>
383 </DL>
384 <HR>
385
386 <A NAME="addProperty(java.lang.String, java.lang.Character)"><!-- --></A><H3>
387 addProperty</H3>
388 <PRE>
389 public void <B>addProperty</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
390 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Character.html?is-external=true" title="class or interface in java.lang">Character</A>&nbsp;value)</PRE>
391 <DL>
392 <DD>Convenience method to add a char member. The specified value is converted to a
393 JsonPrimitive of Character.
394 <P>
395 <DD><DL>
396 <DT><B>Parameters:</B><DD><CODE>property</CODE> - name of the member.<DD><CODE>value</CODE> - the number value associated with the member.</DL>
397 </DD>
398 </DL>
399 <HR>
400
401 <A NAME="entrySet()"><!-- --></A><H3>
402 entrySet</H3>
403 <PRE>
404 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Map.Entry.html?is-external=true" title="class or interface in java.util">Map.Entry</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;&gt; <B>entrySet</B>()</PRE>
405 <DL>
406 <DD>Returns a set of members of this object. The set is ordered, and the order is in which the
407 elements were added.
408 <P>
409 <DD><DL>
410
411 <DT><B>Returns:</B><DD>a set of members of this object.</DL>
412 </DD>
413 </DL>
414 <HR>
415
416 <A NAME="has(java.lang.String)"><!-- --></A><H3>
417 has</H3>
418 <PRE>
419 public boolean <B>has</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</PRE>
420 <DL>
421 <DD>Convenience method to check if a member with the specified name is present in this object.
422 <P>
423 <DD><DL>
424 <DT><B>Parameters:</B><DD><CODE>memberName</CODE> - name of the member that is being checked for presence.
425 <DT><B>Returns:</B><DD>true if there is a member with the specified name, false otherwise.</DL>
426 </DD>
427 </DL>
428 <HR>
429
430 <A NAME="get(java.lang.String)"><!-- --></A><H3>
431 get</H3>
432 <PRE>
433 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>get</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</PRE>
434 <DL>
435 <DD>Returns the member with the specified name.
436 <P>
437 <DD><DL>
438 <DT><B>Parameters:</B><DD><CODE>memberName</CODE> - name of the member that is being requested.
439 <DT><B>Returns:</B><DD>the member matching the name. Null if no such member exists.</DL>
440 </DD>
441 </DL>
442 <HR>
443
444 <A NAME="getAsJsonPrimitive(java.lang.String)"><!-- --></A><H3>
445 getAsJsonPrimitive</H3>
446 <PRE>
447 public <A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A> <B>getAsJsonPrimitive</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</PRE>
448 <DL>
449 <DD>Convenience method to get the specified member as a JsonPrimitive element.
450 <P>
451 <DD><DL>
452 <DT><B>Parameters:</B><DD><CODE>memberName</CODE> - name of the member being requested.
453 <DT><B>Returns:</B><DD>the JsonPrimitive corresponding to the specified member.</DL>
454 </DD>
455 </DL>
456 <HR>
457
458 <A NAME="getAsJsonArray(java.lang.String)"><!-- --></A><H3>
459 getAsJsonArray</H3>
460 <PRE>
461 public <A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A> <B>getAsJsonArray</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</PRE>
462 <DL>
463 <DD>Convenience method to get the specified member as a JsonArray.
464 <P>
465 <DD><DL>
466 <DT><B>Parameters:</B><DD><CODE>memberName</CODE> - name of the member being requested.
467 <DT><B>Returns:</B><DD>the JsonArray corresponding to the specified member.</DL>
468 </DD>
469 </DL>
470 <HR>
471
472 <A NAME="getAsJsonObject(java.lang.String)"><!-- --></A><H3>
473 getAsJsonObject</H3>
474 <PRE>
475 public <A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A> <B>getAsJsonObject</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</PRE>
476 <DL>
477 <DD>Convenience method to get the specified member as a JsonObject.
478 <P>
479 <DD><DL>
480 <DT><B>Parameters:</B><DD><CODE>memberName</CODE> - name of the member being requested.
481 <DT><B>Returns:</B><DD>the JsonObject corresponding to the specified member.</DL>
482 </DD>
483 </DL>
484 <HR>
485
486 <A NAME="equals(java.lang.Object)"><!-- --></A><H3>
487 equals</H3>
488 <PRE>
489 public boolean <B>equals</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;o)</PRE>
490 <DL>
491 <DD><DL>
492 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
493 </DD>
494 <DD><DL>
495 </DL>
496 </DD>
497 </DL>
498 <HR>
499
500 <A NAME="hashCode()"><!-- --></A><H3>
501 hashCode</H3>
502 <PRE>
503 public int <B>hashCode</B>()</PRE>
504 <DL>
505 <DD><DL>
506 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
507 </DD>
508 <DD><DL>
509 </DL>
510 </DD>
511 </DL>
512 <!-- ========= END OF CLASS DATA ========= -->
513 <HR>
514
515
516 <!-- ======= START OF BOTTOM NAVBAR ====== -->
517 <A NAME="navbar_bottom"><!-- --></A>
518 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
519 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
520 <TR>
521 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
522 <A NAME="navbar_bottom_firstrow"><!-- --></A>
523 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
524 <TR ALIGN="center" VALIGN="top">
525 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
526 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
527 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
528 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonObject.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
529 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
530 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
531 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
532 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
533 </TR>
534 </TABLE>
535 </TD>
536 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
537 </EM>
538 </TD>
539 </TR>
540
541 <TR>
542 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
543 &nbsp;<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
544 &nbsp;<A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
545 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
546 <A HREF="../../../index.html?com/google/gson/JsonObject.html" target="_top"><B>FRAMES</B></A> &nbsp;
547 &nbsp;<A HREF="JsonObject.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
548 &nbsp;<SCRIPT type="text/javascript">
549 <!--
550 if(window==top) {
551 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
552 }
553 //-->
554 </SCRIPT>
555 <NOSCRIPT>
556 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
557 </NOSCRIPT>
558
559
560 </FONT></TD>
561 </TR>
562 <TR>
563 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
564 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
565 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
566 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
567 </TR>
568 </TABLE>
569 <A NAME="skip-navbar_bottom"></A>
570 <!-- ======== END OF BOTTOM NAVBAR ======= -->
571
572 <HR>
573 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
574 </BODY>
575 </HTML>
+0
-302
gson/docs/javadocs/com/google/gson/JsonParseException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonParseException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonParseException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonParseException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonParseException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonParseException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonParseException</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">java.lang.Throwable</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">java.lang.Exception</A>
98 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang">java.lang.RuntimeException</A>
99 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonParseException</B>
100 </PRE>
101 <DL>
102 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A></DD>
103 </DL>
104 <DL>
105 <DT><B>Direct Known Subclasses:</B> <DD><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>, <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></DD>
106 </DL>
107 <HR>
108 <DL>
109 <DT><PRE>public class <B>JsonParseException</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang">RuntimeException</A></DL>
110 </PRE>
111
112 <P>
113 This exception is raised if there is a serious issue that occurs during parsing of a Json
114 string. One of the main usages for this class is for the Gson infrastructure. If the incoming
115 Json is bad/malicious, an instance of this exception is raised.
116
117 <p>This exception is a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang"><CODE>RuntimeException</CODE></A> because it is exposed to the client. Using a
118 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang"><CODE>RuntimeException</CODE></A> avoids bad coding practices on the client side where they catch the
119 exception and do nothing. It is often the case that you want to blow up if there is a parsing
120 error (i.e. often clients do not know how to recover from a <A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><CODE>JsonParseException</CODE></A>.</p>
121 <P>
122
123 <P>
124 <DL>
125 <DT><B>Author:</B></DT>
126 <DD>Inderjeet Singh, Joel Leitch</DD>
127 <DT><B>See Also:</B><DD><A HREF="../../../serialized-form.html#com.google.gson.JsonParseException">Serialized Form</A></DL>
128 <HR>
129
130 <P>
131
132 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
133
134 <A NAME="constructor_summary"><!-- --></A>
135 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
136 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
137 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
138 <B>Constructor Summary</B></FONT></TH>
139 </TR>
140 <TR BGCOLOR="white" CLASS="TableRowColor">
141 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParseException.html#JsonParseException(java.lang.String)">JsonParseException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</CODE>
142
143 <BR>
144 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates exception with the specified message.</TD>
145 </TR>
146 <TR BGCOLOR="white" CLASS="TableRowColor">
147 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParseException.html#JsonParseException(java.lang.String, java.lang.Throwable)">JsonParseException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
148 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</CODE>
149
150 <BR>
151 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates exception with the specified message and cause.</TD>
152 </TR>
153 <TR BGCOLOR="white" CLASS="TableRowColor">
154 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParseException.html#JsonParseException(java.lang.Throwable)">JsonParseException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</CODE>
155
156 <BR>
157 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates exception with the specified cause.</TD>
158 </TR>
159 </TABLE>
160 &nbsp;
161 <!-- ========== METHOD SUMMARY =========== -->
162
163 <A NAME="method_summary"><!-- --></A>
164 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
165 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
166 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
167 <B>Method Summary</B></FONT></TH>
168 </TR>
169 </TABLE>
170 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Throwable"><!-- --></A>
171 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
172 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
173 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A></B></TH>
174 </TR>
175 <TR BGCOLOR="white" CLASS="TableRowColor">
176 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#fillInStackTrace()" title="class or interface in java.lang">fillInStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getCause()" title="class or interface in java.lang">getCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getLocalizedMessage()" title="class or interface in java.lang">getLocalizedMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getMessage()" title="class or interface in java.lang">getMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getStackTrace()" title="class or interface in java.lang">getStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#initCause(java.lang.Throwable)" title="class or interface in java.lang">initCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace()" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintStream)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintWriter)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#setStackTrace(java.lang.StackTraceElement[])" title="class or interface in java.lang">setStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE></TD>
177 </TR>
178 </TABLE>
179 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
180 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
181 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
182 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
183 </TR>
184 <TR BGCOLOR="white" CLASS="TableRowColor">
185 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
186 </TR>
187 </TABLE>
188 &nbsp;
189 <P>
190
191 <!-- ========= CONSTRUCTOR DETAIL ======== -->
192
193 <A NAME="constructor_detail"><!-- --></A>
194 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
195 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
196 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
197 <B>Constructor Detail</B></FONT></TH>
198 </TR>
199 </TABLE>
200
201 <A NAME="JsonParseException(java.lang.String)"><!-- --></A><H3>
202 JsonParseException</H3>
203 <PRE>
204 public <B>JsonParseException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</PRE>
205 <DL>
206 <DD>Creates exception with the specified message. If you are wrapping another exception, consider
207 using <A HREF="../../../com/google/gson/JsonParseException.html#JsonParseException(java.lang.String, java.lang.Throwable)"><CODE>JsonParseException(String, Throwable)</CODE></A> instead.
208 <P>
209 <DL>
210 <DT><B>Parameters:</B><DD><CODE>msg</CODE> - error message describing a possible cause of this exception.</DL>
211 </DL>
212 <HR>
213
214 <A NAME="JsonParseException(java.lang.String, java.lang.Throwable)"><!-- --></A><H3>
215 JsonParseException</H3>
216 <PRE>
217 public <B>JsonParseException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
218 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</PRE>
219 <DL>
220 <DD>Creates exception with the specified message and cause.
221 <P>
222 <DL>
223 <DT><B>Parameters:</B><DD><CODE>msg</CODE> - error message describing what happened.<DD><CODE>cause</CODE> - root exception that caused this exception to be thrown.</DL>
224 </DL>
225 <HR>
226
227 <A NAME="JsonParseException(java.lang.Throwable)"><!-- --></A><H3>
228 JsonParseException</H3>
229 <PRE>
230 public <B>JsonParseException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</PRE>
231 <DL>
232 <DD>Creates exception with the specified cause. Consider using
233 <A HREF="../../../com/google/gson/JsonParseException.html#JsonParseException(java.lang.String, java.lang.Throwable)"><CODE>JsonParseException(String, Throwable)</CODE></A> instead if you can describe what happened.
234 <P>
235 <DL>
236 <DT><B>Parameters:</B><DD><CODE>cause</CODE> - root exception that caused this exception to be thrown.</DL>
237 </DL>
238 <!-- ========= END OF CLASS DATA ========= -->
239 <HR>
240
241
242 <!-- ======= START OF BOTTOM NAVBAR ====== -->
243 <A NAME="navbar_bottom"><!-- --></A>
244 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
245 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
246 <TR>
247 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
248 <A NAME="navbar_bottom_firstrow"><!-- --></A>
249 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
250 <TR ALIGN="center" VALIGN="top">
251 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
252 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
253 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
254 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonParseException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
255 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
256 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
257 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
258 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
259 </TR>
260 </TABLE>
261 </TD>
262 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
263 </EM>
264 </TD>
265 </TR>
266
267 <TR>
268 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
269 &nbsp;<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
270 &nbsp;<A HREF="../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
271 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
272 <A HREF="../../../index.html?com/google/gson/JsonParseException.html" target="_top"><B>FRAMES</B></A> &nbsp;
273 &nbsp;<A HREF="JsonParseException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
274 &nbsp;<SCRIPT type="text/javascript">
275 <!--
276 if(window==top) {
277 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
278 }
279 //-->
280 </SCRIPT>
281 <NOSCRIPT>
282 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
283 </NOSCRIPT>
284
285
286 </FONT></TD>
287 </TR>
288 <TR>
289 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
290 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
291 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
292 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
293 </TR>
294 </TABLE>
295 <A NAME="skip-navbar_bottom"></A>
296 <!-- ======== END OF BOTTOM NAVBAR ======= -->
297
298 <HR>
299 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
300 </BODY>
301 </HTML>
+0
-332
gson/docs/javadocs/com/google/gson/JsonParser.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonParser (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonParser (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonParser.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonParser</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonParser</B>
97 </PRE>
98 <HR>
99 <DL>
100 <DT><PRE>public final class <B>JsonParser</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101 </PRE>
102
103 <P>
104 A parser to parse Json into a parse tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s
105 <P>
106
107 <P>
108 <DL>
109 <DT><B>Since:</B></DT>
110 <DD>1.3</DD>
111 <DT><B>Author:</B></DT>
112 <DD>Inderjeet Singh, Joel Leitch</DD>
113 </DL>
114 <HR>
115
116 <P>
117
118 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
119
120 <A NAME="constructor_summary"><!-- --></A>
121 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
122 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
123 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
124 <B>Constructor Summary</B></FONT></TH>
125 </TR>
126 <TR BGCOLOR="white" CLASS="TableRowColor">
127 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParser.html#JsonParser()">JsonParser</A></B>()</CODE>
128
129 <BR>
130 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
131 </TR>
132 </TABLE>
133 &nbsp;
134 <!-- ========== METHOD SUMMARY =========== -->
135
136 <A NAME="method_summary"><!-- --></A>
137 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
138 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
139 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
140 <B>Method Summary</B></FONT></TH>
141 </TR>
142 <TR BGCOLOR="white" CLASS="TableRowColor">
143 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
144 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
145 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParser.html#parse(com.google.gson.stream.JsonReader)">parse</A></B>(<A HREF="../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;json)</CODE>
146
147 <BR>
148 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next value from the JSON stream as a parse tree.</TD>
149 </TR>
150 <TR BGCOLOR="white" CLASS="TableRowColor">
151 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
152 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
153 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParser.html#parse(java.io.Reader)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json)</CODE>
154
155 <BR>
156 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
157 </TR>
158 <TR BGCOLOR="white" CLASS="TableRowColor">
159 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
160 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
161 <TD><CODE><B><A HREF="../../../com/google/gson/JsonParser.html#parse(java.lang.String)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)</CODE>
162
163 <BR>
164 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
165 </TR>
166 </TABLE>
167 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
168 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
169 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
170 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
171 </TR>
172 <TR BGCOLOR="white" CLASS="TableRowColor">
173 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
174 </TR>
175 </TABLE>
176 &nbsp;
177 <P>
178
179 <!-- ========= CONSTRUCTOR DETAIL ======== -->
180
181 <A NAME="constructor_detail"><!-- --></A>
182 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
183 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
184 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
185 <B>Constructor Detail</B></FONT></TH>
186 </TR>
187 </TABLE>
188
189 <A NAME="JsonParser()"><!-- --></A><H3>
190 JsonParser</H3>
191 <PRE>
192 public <B>JsonParser</B>()</PRE>
193 <DL>
194 </DL>
195
196 <!-- ============ METHOD DETAIL ========== -->
197
198 <A NAME="method_detail"><!-- --></A>
199 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
200 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
201 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
202 <B>Method Detail</B></FONT></TH>
203 </TR>
204 </TABLE>
205
206 <A NAME="parse(java.lang.String)"><!-- --></A><H3>
207 parse</H3>
208 <PRE>
209 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>parse</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)
210 throws <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
211 <DL>
212 <DD>Parses the specified JSON string into a parse tree
213 <P>
214 <DD><DL>
215 <DT><B>Parameters:</B><DD><CODE>json</CODE> - JSON text
216 <DT><B>Returns:</B><DD>a parse tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s corresponding to the specified JSON
217 <DT><B>Throws:</B>
218 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if the specified text is not valid JSON
219 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE><DT><B>Since:</B></DT>
220 <DD>1.3</DD>
221 </DL>
222 </DD>
223 </DL>
224 <HR>
225
226 <A NAME="parse(java.io.Reader)"><!-- --></A><H3>
227 parse</H3>
228 <PRE>
229 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>parse</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json)
230 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>,
231 <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
232 <DL>
233 <DD>Parses the specified JSON string into a parse tree
234 <P>
235 <DD><DL>
236 <DT><B>Parameters:</B><DD><CODE>json</CODE> - JSON text
237 <DT><B>Returns:</B><DD>a parse tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s corresponding to the specified JSON
238 <DT><B>Throws:</B>
239 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if the specified text is not valid JSON
240 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE>
241 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE><DT><B>Since:</B></DT>
242 <DD>1.3</DD>
243 </DL>
244 </DD>
245 </DL>
246 <HR>
247
248 <A NAME="parse(com.google.gson.stream.JsonReader)"><!-- --></A><H3>
249 parse</H3>
250 <PRE>
251 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>parse</B>(<A HREF="../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;json)
252 throws <A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>,
253 <A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></PRE>
254 <DL>
255 <DD>Returns the next value from the JSON stream as a parse tree.
256 <P>
257 <DD><DL>
258
259 <DT><B>Throws:</B>
260 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if there is an IOException or if the specified
261 text is not valid JSON
262 <DD><CODE><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></CODE>
263 <DD><CODE><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></CODE><DT><B>Since:</B></DT>
264 <DD>1.6</DD>
265 </DL>
266 </DD>
267 </DL>
268 <!-- ========= END OF CLASS DATA ========= -->
269 <HR>
270
271
272 <!-- ======= START OF BOTTOM NAVBAR ====== -->
273 <A NAME="navbar_bottom"><!-- --></A>
274 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
275 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
276 <TR>
277 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
278 <A NAME="navbar_bottom_firstrow"><!-- --></A>
279 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
280 <TR ALIGN="center" VALIGN="top">
281 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
282 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
283 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
284 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonParser.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
285 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
286 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
287 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
288 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
289 </TR>
290 </TABLE>
291 </TD>
292 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
293 </EM>
294 </TD>
295 </TR>
296
297 <TR>
298 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
299 &nbsp;<A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
300 &nbsp;<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
301 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
302 <A HREF="../../../index.html?com/google/gson/JsonParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
303 &nbsp;<A HREF="JsonParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
304 &nbsp;<SCRIPT type="text/javascript">
305 <!--
306 if(window==top) {
307 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
308 }
309 //-->
310 </SCRIPT>
311 <NOSCRIPT>
312 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
313 </NOSCRIPT>
314
315
316 </FONT></TD>
317 </TR>
318 <TR>
319 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
320 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
321 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
322 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
323 </TR>
324 </TABLE>
325 <A NAME="skip-navbar_bottom"></A>
326 <!-- ======== END OF BOTTOM NAVBAR ======= -->
327
328 <HR>
329 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
330 </BODY>
331 </HTML>
+0
-741
gson/docs/javadocs/com/google/gson/JsonPrimitive.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonPrimitive (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonPrimitive (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonPrimitive.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonPrimitive.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonPrimitive.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonPrimitive</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">com.google.gson.JsonElement</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonPrimitive</B>
98 </PRE>
99 <HR>
100 <DL>
101 <DT><PRE>public final class <B>JsonPrimitive</B><DT>extends <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></DL>
102 </PRE>
103
104 <P>
105 A class representing a Json primitive value. A primitive value
106 is either a String, a Java primitive, or a Java primitive
107 wrapper type.
108 <P>
109
110 <P>
111 <DL>
112 <DT><B>Author:</B></DT>
113 <DD>Inderjeet Singh, Joel Leitch</DD>
114 </DL>
115 <HR>
116
117 <P>
118
119 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
120
121 <A NAME="constructor_summary"><!-- --></A>
122 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
123 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
124 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
125 <B>Constructor Summary</B></FONT></TH>
126 </TR>
127 <TR BGCOLOR="white" CLASS="TableRowColor">
128 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.Boolean)">JsonPrimitive</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</A>&nbsp;bool)</CODE>
129
130 <BR>
131 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create a primitive containing a boolean value.</TD>
132 </TR>
133 <TR BGCOLOR="white" CLASS="TableRowColor">
134 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.Character)">JsonPrimitive</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Character.html?is-external=true" title="class or interface in java.lang">Character</A>&nbsp;c)</CODE>
135
136 <BR>
137 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create a primitive containing a character.</TD>
138 </TR>
139 <TR BGCOLOR="white" CLASS="TableRowColor">
140 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.Number)">JsonPrimitive</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;number)</CODE>
141
142 <BR>
143 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create a primitive containing a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.</TD>
144 </TR>
145 <TR BGCOLOR="white" CLASS="TableRowColor">
146 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.String)">JsonPrimitive</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;string)</CODE>
147
148 <BR>
149 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Create a primitive containing a String value.</TD>
150 </TR>
151 </TABLE>
152 &nbsp;
153 <!-- ========== METHOD SUMMARY =========== -->
154
155 <A NAME="method_summary"><!-- --></A>
156 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
157 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
158 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
159 <B>Method Summary</B></FONT></TH>
160 </TR>
161 <TR BGCOLOR="white" CLASS="TableRowColor">
162 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
163 <CODE>&nbsp;boolean</CODE></FONT></TD>
164 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#equals(java.lang.Object)">equals</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;obj)</CODE>
165
166 <BR>
167 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
168 </TR>
169 <TR BGCOLOR="white" CLASS="TableRowColor">
170 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
171 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math">BigDecimal</A></CODE></FONT></TD>
172 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsBigDecimal()">getAsBigDecimal</A></B>()</CODE>
173
174 <BR>
175 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.</TD>
176 </TR>
177 <TR BGCOLOR="white" CLASS="TableRowColor">
178 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
179 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</A></CODE></FONT></TD>
180 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsBigInteger()">getAsBigInteger</A></B>()</CODE>
181
182 <BR>
183 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.</TD>
184 </TR>
185 <TR BGCOLOR="white" CLASS="TableRowColor">
186 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
187 <CODE>&nbsp;boolean</CODE></FONT></TD>
188 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsBoolean()">getAsBoolean</A></B>()</CODE>
189
190 <BR>
191 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a boolean value.</TD>
192 </TR>
193 <TR BGCOLOR="white" CLASS="TableRowColor">
194 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
195 <CODE>&nbsp;byte</CODE></FONT></TD>
196 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsByte()">getAsByte</A></B>()</CODE>
197
198 <BR>
199 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive byte value.</TD>
200 </TR>
201 <TR BGCOLOR="white" CLASS="TableRowColor">
202 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
203 <CODE>&nbsp;char</CODE></FONT></TD>
204 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsCharacter()">getAsCharacter</A></B>()</CODE>
205
206 <BR>
207 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive character value.</TD>
208 </TR>
209 <TR BGCOLOR="white" CLASS="TableRowColor">
210 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
211 <CODE>&nbsp;double</CODE></FONT></TD>
212 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsDouble()">getAsDouble</A></B>()</CODE>
213
214 <BR>
215 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive double.</TD>
216 </TR>
217 <TR BGCOLOR="white" CLASS="TableRowColor">
218 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
219 <CODE>&nbsp;float</CODE></FONT></TD>
220 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsFloat()">getAsFloat</A></B>()</CODE>
221
222 <BR>
223 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a float.</TD>
224 </TR>
225 <TR BGCOLOR="white" CLASS="TableRowColor">
226 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
227 <CODE>&nbsp;int</CODE></FONT></TD>
228 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsInt()">getAsInt</A></B>()</CODE>
229
230 <BR>
231 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive integer.</TD>
232 </TR>
233 <TR BGCOLOR="white" CLASS="TableRowColor">
234 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
235 <CODE>&nbsp;long</CODE></FONT></TD>
236 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsLong()">getAsLong</A></B>()</CODE>
237
238 <BR>
239 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive long.</TD>
240 </TR>
241 <TR BGCOLOR="white" CLASS="TableRowColor">
242 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
243 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A></CODE></FONT></TD>
244 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsNumber()">getAsNumber</A></B>()</CODE>
245
246 <BR>
247 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a Number.</TD>
248 </TR>
249 <TR BGCOLOR="white" CLASS="TableRowColor">
250 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
251 <CODE>&nbsp;short</CODE></FONT></TD>
252 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsShort()">getAsShort</A></B>()</CODE>
253
254 <BR>
255 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a primitive short.</TD>
256 </TR>
257 <TR BGCOLOR="white" CLASS="TableRowColor">
258 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
259 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
260 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#getAsString()">getAsString</A></B>()</CODE>
261
262 <BR>
263 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a String.</TD>
264 </TR>
265 <TR BGCOLOR="white" CLASS="TableRowColor">
266 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
267 <CODE>&nbsp;int</CODE></FONT></TD>
268 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#hashCode()">hashCode</A></B>()</CODE>
269
270 <BR>
271 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
272 </TR>
273 <TR BGCOLOR="white" CLASS="TableRowColor">
274 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
275 <CODE>&nbsp;boolean</CODE></FONT></TD>
276 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#isBoolean()">isBoolean</A></B>()</CODE>
277
278 <BR>
279 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Check whether this primitive contains a boolean value.</TD>
280 </TR>
281 <TR BGCOLOR="white" CLASS="TableRowColor">
282 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
283 <CODE>&nbsp;boolean</CODE></FONT></TD>
284 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#isNumber()">isNumber</A></B>()</CODE>
285
286 <BR>
287 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Check whether this primitive contains a Number.</TD>
288 </TR>
289 <TR BGCOLOR="white" CLASS="TableRowColor">
290 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
291 <CODE>&nbsp;boolean</CODE></FONT></TD>
292 <TD><CODE><B><A HREF="../../../com/google/gson/JsonPrimitive.html#isString()">isString</A></B>()</CODE>
293
294 <BR>
295 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Check whether this primitive contains a String value.</TD>
296 </TR>
297 </TABLE>
298 &nbsp;<A NAME="methods_inherited_from_class_com.google.gson.JsonElement"><!-- --></A>
299 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
300 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
301 <TH ALIGN="left"><B>Methods inherited from class com.google.gson.<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></B></TH>
302 </TR>
303 <TR BGCOLOR="white" CLASS="TableRowColor">
304 <TD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsJsonArray()">getAsJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonNull()">getAsJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonObject()">getAsJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#getAsJsonPrimitive()">getAsJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonArray()">isJsonArray</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonNull()">isJsonNull</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonObject()">isJsonObject</A>, <A HREF="../../../com/google/gson/JsonElement.html#isJsonPrimitive()">isJsonPrimitive</A>, <A HREF="../../../com/google/gson/JsonElement.html#toString()">toString</A></CODE></TD>
305 </TR>
306 </TABLE>
307 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
308 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
309 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
310 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
311 </TR>
312 <TR BGCOLOR="white" CLASS="TableRowColor">
313 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
314 </TR>
315 </TABLE>
316 &nbsp;
317 <P>
318
319 <!-- ========= CONSTRUCTOR DETAIL ======== -->
320
321 <A NAME="constructor_detail"><!-- --></A>
322 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
323 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
324 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
325 <B>Constructor Detail</B></FONT></TH>
326 </TR>
327 </TABLE>
328
329 <A NAME="JsonPrimitive(java.lang.Boolean)"><!-- --></A><H3>
330 JsonPrimitive</H3>
331 <PRE>
332 public <B>JsonPrimitive</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</A>&nbsp;bool)</PRE>
333 <DL>
334 <DD>Create a primitive containing a boolean value.
335 <P>
336 <DL>
337 <DT><B>Parameters:</B><DD><CODE>bool</CODE> - the value to create the primitive with.</DL>
338 </DL>
339 <HR>
340
341 <A NAME="JsonPrimitive(java.lang.Number)"><!-- --></A><H3>
342 JsonPrimitive</H3>
343 <PRE>
344 public <B>JsonPrimitive</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;number)</PRE>
345 <DL>
346 <DD>Create a primitive containing a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.
347 <P>
348 <DL>
349 <DT><B>Parameters:</B><DD><CODE>number</CODE> - the value to create the primitive with.</DL>
350 </DL>
351 <HR>
352
353 <A NAME="JsonPrimitive(java.lang.String)"><!-- --></A><H3>
354 JsonPrimitive</H3>
355 <PRE>
356 public <B>JsonPrimitive</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;string)</PRE>
357 <DL>
358 <DD>Create a primitive containing a String value.
359 <P>
360 <DL>
361 <DT><B>Parameters:</B><DD><CODE>string</CODE> - the value to create the primitive with.</DL>
362 </DL>
363 <HR>
364
365 <A NAME="JsonPrimitive(java.lang.Character)"><!-- --></A><H3>
366 JsonPrimitive</H3>
367 <PRE>
368 public <B>JsonPrimitive</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Character.html?is-external=true" title="class or interface in java.lang">Character</A>&nbsp;c)</PRE>
369 <DL>
370 <DD>Create a primitive containing a character. The character is turned into a one character String
371 since Json only supports String.
372 <P>
373 <DL>
374 <DT><B>Parameters:</B><DD><CODE>c</CODE> - the value to create the primitive with.</DL>
375 </DL>
376
377 <!-- ============ METHOD DETAIL ========== -->
378
379 <A NAME="method_detail"><!-- --></A>
380 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
381 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
382 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
383 <B>Method Detail</B></FONT></TH>
384 </TR>
385 </TABLE>
386
387 <A NAME="isBoolean()"><!-- --></A><H3>
388 isBoolean</H3>
389 <PRE>
390 public boolean <B>isBoolean</B>()</PRE>
391 <DL>
392 <DD>Check whether this primitive contains a boolean value.
393 <P>
394 <DD><DL>
395
396 <DT><B>Returns:</B><DD>true if this primitive contains a boolean value, false otherwise.</DL>
397 </DD>
398 </DL>
399 <HR>
400
401 <A NAME="getAsBoolean()"><!-- --></A><H3>
402 getAsBoolean</H3>
403 <PRE>
404 public boolean <B>getAsBoolean</B>()</PRE>
405 <DL>
406 <DD>convenience method to get this element as a boolean value.
407 <P>
408 <DD><DL>
409 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBoolean()">getAsBoolean</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
410 </DD>
411 <DD><DL>
412
413 <DT><B>Returns:</B><DD>get this element as a primitive boolean value.</DL>
414 </DD>
415 </DL>
416 <HR>
417
418 <A NAME="isNumber()"><!-- --></A><H3>
419 isNumber</H3>
420 <PRE>
421 public boolean <B>isNumber</B>()</PRE>
422 <DL>
423 <DD>Check whether this primitive contains a Number.
424 <P>
425 <DD><DL>
426
427 <DT><B>Returns:</B><DD>true if this primitive contains a Number, false otherwise.</DL>
428 </DD>
429 </DL>
430 <HR>
431
432 <A NAME="getAsNumber()"><!-- --></A><H3>
433 getAsNumber</H3>
434 <PRE>
435 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A> <B>getAsNumber</B>()</PRE>
436 <DL>
437 <DD>convenience method to get this element as a Number.
438 <P>
439 <DD><DL>
440 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsNumber()">getAsNumber</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
441 </DD>
442 <DD><DL>
443
444 <DT><B>Returns:</B><DD>get this element as a Number.
445 <DT><B>Throws:</B>
446 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid Number.</DL>
447 </DD>
448 </DL>
449 <HR>
450
451 <A NAME="isString()"><!-- --></A><H3>
452 isString</H3>
453 <PRE>
454 public boolean <B>isString</B>()</PRE>
455 <DL>
456 <DD>Check whether this primitive contains a String value.
457 <P>
458 <DD><DL>
459
460 <DT><B>Returns:</B><DD>true if this primitive contains a String value, false otherwise.</DL>
461 </DD>
462 </DL>
463 <HR>
464
465 <A NAME="getAsString()"><!-- --></A><H3>
466 getAsString</H3>
467 <PRE>
468 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getAsString</B>()</PRE>
469 <DL>
470 <DD>convenience method to get this element as a String.
471 <P>
472 <DD><DL>
473 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsString()">getAsString</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
474 </DD>
475 <DD><DL>
476
477 <DT><B>Returns:</B><DD>get this element as a String.</DL>
478 </DD>
479 </DL>
480 <HR>
481
482 <A NAME="getAsDouble()"><!-- --></A><H3>
483 getAsDouble</H3>
484 <PRE>
485 public double <B>getAsDouble</B>()</PRE>
486 <DL>
487 <DD>convenience method to get this element as a primitive double.
488 <P>
489 <DD><DL>
490 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsDouble()">getAsDouble</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
491 </DD>
492 <DD><DL>
493
494 <DT><B>Returns:</B><DD>get this element as a primitive double.
495 <DT><B>Throws:</B>
496 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid double.</DL>
497 </DD>
498 </DL>
499 <HR>
500
501 <A NAME="getAsBigDecimal()"><!-- --></A><H3>
502 getAsBigDecimal</H3>
503 <PRE>
504 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math">BigDecimal</A> <B>getAsBigDecimal</B>()</PRE>
505 <DL>
506 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
507 <P>
508 <DD><DL>
509 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBigDecimal()">getAsBigDecimal</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
510 </DD>
511 <DD><DL>
512
513 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
514 <DT><B>Throws:</B>
515 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.</DL>
516 </DD>
517 </DL>
518 <HR>
519
520 <A NAME="getAsBigInteger()"><!-- --></A><H3>
521 getAsBigInteger</H3>
522 <PRE>
523 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math">BigInteger</A> <B>getAsBigInteger</B>()</PRE>
524 <DL>
525 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
526 <P>
527 <DD><DL>
528 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsBigInteger()">getAsBigInteger</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
529 </DD>
530 <DD><DL>
531
532 <DT><B>Returns:</B><DD>get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
533 <DT><B>Throws:</B>
534 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.</DL>
535 </DD>
536 </DL>
537 <HR>
538
539 <A NAME="getAsFloat()"><!-- --></A><H3>
540 getAsFloat</H3>
541 <PRE>
542 public float <B>getAsFloat</B>()</PRE>
543 <DL>
544 <DD>convenience method to get this element as a float.
545 <P>
546 <DD><DL>
547 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsFloat()">getAsFloat</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
548 </DD>
549 <DD><DL>
550
551 <DT><B>Returns:</B><DD>get this element as a float.
552 <DT><B>Throws:</B>
553 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid float.</DL>
554 </DD>
555 </DL>
556 <HR>
557
558 <A NAME="getAsLong()"><!-- --></A><H3>
559 getAsLong</H3>
560 <PRE>
561 public long <B>getAsLong</B>()</PRE>
562 <DL>
563 <DD>convenience method to get this element as a primitive long.
564 <P>
565 <DD><DL>
566 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsLong()">getAsLong</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
567 </DD>
568 <DD><DL>
569
570 <DT><B>Returns:</B><DD>get this element as a primitive long.
571 <DT><B>Throws:</B>
572 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid long.</DL>
573 </DD>
574 </DL>
575 <HR>
576
577 <A NAME="getAsShort()"><!-- --></A><H3>
578 getAsShort</H3>
579 <PRE>
580 public short <B>getAsShort</B>()</PRE>
581 <DL>
582 <DD>convenience method to get this element as a primitive short.
583 <P>
584 <DD><DL>
585 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsShort()">getAsShort</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
586 </DD>
587 <DD><DL>
588
589 <DT><B>Returns:</B><DD>get this element as a primitive short.
590 <DT><B>Throws:</B>
591 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid short value.</DL>
592 </DD>
593 </DL>
594 <HR>
595
596 <A NAME="getAsInt()"><!-- --></A><H3>
597 getAsInt</H3>
598 <PRE>
599 public int <B>getAsInt</B>()</PRE>
600 <DL>
601 <DD>convenience method to get this element as a primitive integer.
602 <P>
603 <DD><DL>
604 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsInt()">getAsInt</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
605 </DD>
606 <DD><DL>
607
608 <DT><B>Returns:</B><DD>get this element as a primitive integer.
609 <DT><B>Throws:</B>
610 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the value contained is not a valid integer.</DL>
611 </DD>
612 </DL>
613 <HR>
614
615 <A NAME="getAsByte()"><!-- --></A><H3>
616 getAsByte</H3>
617 <PRE>
618 public byte <B>getAsByte</B>()</PRE>
619 <DL>
620 <DD><B>Description copied from class: <CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">JsonElement</A></CODE></B></DD>
621 <DD>convenience method to get this element as a primitive byte value.
622 <P>
623 <DD><DL>
624 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsByte()">getAsByte</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
625 </DD>
626 <DD><DL>
627
628 <DT><B>Returns:</B><DD>get this element as a primitive byte value.</DL>
629 </DD>
630 </DL>
631 <HR>
632
633 <A NAME="getAsCharacter()"><!-- --></A><H3>
634 getAsCharacter</H3>
635 <PRE>
636 public char <B>getAsCharacter</B>()</PRE>
637 <DL>
638 <DD><B>Description copied from class: <CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">JsonElement</A></CODE></B></DD>
639 <DD>convenience method to get this element as a primitive character value.
640 <P>
641 <DD><DL>
642 <DT><B>Overrides:</B><DD><CODE><A HREF="../../../com/google/gson/JsonElement.html#getAsCharacter()">getAsCharacter</A></CODE> in class <CODE><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></DL>
643 </DD>
644 <DD><DL>
645
646 <DT><B>Returns:</B><DD>get this element as a primitive char value.</DL>
647 </DD>
648 </DL>
649 <HR>
650
651 <A NAME="hashCode()"><!-- --></A><H3>
652 hashCode</H3>
653 <PRE>
654 public int <B>hashCode</B>()</PRE>
655 <DL>
656 <DD><DL>
657 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
658 </DD>
659 <DD><DL>
660 </DL>
661 </DD>
662 </DL>
663 <HR>
664
665 <A NAME="equals(java.lang.Object)"><!-- --></A><H3>
666 equals</H3>
667 <PRE>
668 public boolean <B>equals</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;obj)</PRE>
669 <DL>
670 <DD><DL>
671 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
672 </DD>
673 <DD><DL>
674 </DL>
675 </DD>
676 </DL>
677 <!-- ========= END OF CLASS DATA ========= -->
678 <HR>
679
680
681 <!-- ======= START OF BOTTOM NAVBAR ====== -->
682 <A NAME="navbar_bottom"><!-- --></A>
683 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
684 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
685 <TR>
686 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
687 <A NAME="navbar_bottom_firstrow"><!-- --></A>
688 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
689 <TR ALIGN="center" VALIGN="top">
690 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
691 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
692 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
693 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonPrimitive.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
694 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
695 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
696 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
697 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
698 </TR>
699 </TABLE>
700 </TD>
701 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
702 </EM>
703 </TD>
704 </TR>
705
706 <TR>
707 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
708 &nbsp;<A HREF="../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
709 &nbsp;<A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
710 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
711 <A HREF="../../../index.html?com/google/gson/JsonPrimitive.html" target="_top"><B>FRAMES</B></A> &nbsp;
712 &nbsp;<A HREF="JsonPrimitive.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
713 &nbsp;<SCRIPT type="text/javascript">
714 <!--
715 if(window==top) {
716 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
717 }
718 //-->
719 </SCRIPT>
720 <NOSCRIPT>
721 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
722 </NOSCRIPT>
723
724
725 </FONT></TD>
726 </TR>
727 <TR>
728 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
729 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
730 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
731 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
732 </TR>
733 </TABLE>
734 <A NAME="skip-navbar_bottom"></A>
735 <!-- ======== END OF BOTTOM NAVBAR ======= -->
736
737 <HR>
738 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
739 </BODY>
740 </HTML>
+0
-246
gson/docs/javadocs/com/google/gson/JsonSerializationContext.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonSerializationContext (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonSerializationContext (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonSerializationContext.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonSerializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonSerializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface JsonSerializationContext</H2>
94 <HR>
95 <DL>
96 <DT><PRE>public interface <B>JsonSerializationContext</B></DL>
97 </PRE>
98
99 <P>
100 Context for serialization that is passed to a custom serializer during invocation of its
101 <A HREF="../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><CODE>JsonSerializer.serialize(Object, Type, JsonSerializationContext)</CODE></A> method.
102 <P>
103
104 <P>
105 <DL>
106 <DT><B>Author:</B></DT>
107 <DD>Inderjeet Singh, Joel Leitch</DD>
108 </DL>
109 <HR>
110
111 <P>
112
113 <!-- ========== METHOD SUMMARY =========== -->
114
115 <A NAME="method_summary"><!-- --></A>
116 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
117 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
118 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
119 <B>Method Summary</B></FONT></TH>
120 </TR>
121 <TR BGCOLOR="white" CLASS="TableRowColor">
122 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
123 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
124 <TD><CODE><B><A HREF="../../../com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object)">serialize</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</CODE>
125
126 <BR>
127 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default serialization on the specified object.</TD>
128 </TR>
129 <TR BGCOLOR="white" CLASS="TableRowColor">
130 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
131 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
132 <TD><CODE><B><A HREF="../../../com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object, java.lang.reflect.Type)">serialize</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
133 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default serialization on the specified object passing the specific type information.</TD>
137 </TR>
138 </TABLE>
139 &nbsp;
140 <P>
141
142 <!-- ============ METHOD DETAIL ========== -->
143
144 <A NAME="method_detail"><!-- --></A>
145 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
146 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
147 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
148 <B>Method Detail</B></FONT></TH>
149 </TR>
150 </TABLE>
151
152 <A NAME="serialize(java.lang.Object)"><!-- --></A><H3>
153 serialize</H3>
154 <PRE>
155 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>serialize</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</PRE>
156 <DL>
157 <DD>Invokes default serialization on the specified object.
158 <P>
159 <DD><DL>
160 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object that needs to be serialized.
161 <DT><B>Returns:</B><DD>a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s corresponding to the serialized form of <code>src</code>.</DL>
162 </DD>
163 </DL>
164 <HR>
165
166 <A NAME="serialize(java.lang.Object, java.lang.reflect.Type)"><!-- --></A><H3>
167 serialize</H3>
168 <PRE>
169 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>serialize</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
170 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</PRE>
171 <DL>
172 <DD>Invokes default serialization on the specified object passing the specific type information.
173 It should never be invoked on the element received as a parameter of the
174 <A HREF="../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><CODE>JsonSerializer.serialize(Object, Type, JsonSerializationContext)</CODE></A> method. Doing
175 so will result in an infinite loop since Gson will in-turn call the custom serializer again.
176 <P>
177 <DD><DL>
178 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object that needs to be serialized.<DD><CODE>typeOfSrc</CODE> - the actual genericized type of src object.
179 <DT><B>Returns:</B><DD>a tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s corresponding to the serialized form of <code>src</code>.</DL>
180 </DD>
181 </DL>
182 <!-- ========= END OF CLASS DATA ========= -->
183 <HR>
184
185
186 <!-- ======= START OF BOTTOM NAVBAR ====== -->
187 <A NAME="navbar_bottom"><!-- --></A>
188 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
189 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
190 <TR>
191 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
192 <A NAME="navbar_bottom_firstrow"><!-- --></A>
193 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
194 <TR ALIGN="center" VALIGN="top">
195 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
196 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
197 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
198 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonSerializationContext.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
199 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
200 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
201 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
202 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
203 </TR>
204 </TABLE>
205 </TD>
206 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
207 </EM>
208 </TD>
209 </TR>
210
211 <TR>
212 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
213 &nbsp;<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
214 &nbsp;<A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
215 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
216 <A HREF="../../../index.html?com/google/gson/JsonSerializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
217 &nbsp;<A HREF="JsonSerializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
218 &nbsp;<SCRIPT type="text/javascript">
219 <!--
220 if(window==top) {
221 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
222 }
223 //-->
224 </SCRIPT>
225 <NOSCRIPT>
226 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
227 </NOSCRIPT>
228
229
230 </FONT></TD>
231 </TR>
232 <TR>
233 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
234 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
235 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
236 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
237 </TR>
238 </TABLE>
239 <A NAME="skip-navbar_bottom"></A>
240 <!-- ======== END OF BOTTOM NAVBAR ======= -->
241
242 <HR>
243 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
244 </BODY>
245 </HTML>
+0
-275
gson/docs/javadocs/com/google/gson/JsonSerializer.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonSerializer (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonSerializer (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonSerializer.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonSerializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonSerializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface JsonSerializer&lt;T&gt;</H2>
94 <DL>
95 <DT><DT><B>Type Parameters:</B><DD><CODE>T</CODE> - type for which the serializer is being registered. It is possible that a serializer
96 may be asked to serialize a specific generic type of the T.</DL>
97 <HR>
98 <DL>
99 <DT><PRE>public interface <B>JsonSerializer&lt;T&gt;</B></DL>
100 </PRE>
101
102 <P>
103 Interface representing a custom serializer for Json. You should write a custom serializer, if
104 you are not happy with the default serialization done by Gson. You will also need to register
105 this serializer through <A HREF="../../../com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)"><CODE>GsonBuilder.registerTypeAdapter(Type, Object)</CODE></A>.
106
107 <p>Let us look at example where defining a serializer will be useful. The <code>Id</code> class
108 defined below has two fields: <code>clazz</code> and <code>value</code>.</p>
109
110 <p><pre>
111 public class Id&lt;T&gt; {
112 private final Class&lt;T&gt; clazz;
113 private final long value;
114
115 public Id(Class&lt;T&gt; clazz, long value) {
116 this.clazz = clazz;
117 this.value = value;
118 }
119
120 public long getValue() {
121 return value;
122 }
123 }
124 </pre></p>
125
126 <p>The default serialization of <code>Id(com.foo.MyObject.class, 20L)</code> will be
127 <code>{"clazz":com.foo.MyObject,"value":20}</code>. Suppose, you just want the output to be
128 the value instead, which is <code>20</code> in this case. You can achieve that by writing a custom
129 serializer:</p>
130
131 <p><pre>
132 class IdSerializer implements JsonSerializer&lt;Id&gt;() {
133 public JsonElement serialize(Id id, Type typeOfId, JsonSerializationContext context) {
134 return new JsonPrimitive(id.getValue());
135 }
136 }
137 </pre></p>
138
139 <p>You will also need to register <code>IdSerializer</code> with Gson as follows:</p>
140 <pre>
141 Gson gson = new GsonBuilder().registerTypeAdapter(Id.class, new IdSerializer()).create();
142 </pre>
143
144 <p>New applications should prefer <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A>, whose streaming API
145 is more efficient than this interface's tree API.
146 <P>
147
148 <P>
149 <DL>
150 <DT><B>Author:</B></DT>
151 <DD>Inderjeet Singh, Joel Leitch</DD>
152 </DL>
153 <HR>
154
155 <P>
156
157 <!-- ========== METHOD SUMMARY =========== -->
158
159 <A NAME="method_summary"><!-- --></A>
160 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
161 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
162 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
163 <B>Method Summary</B></FONT></TH>
164 </TR>
165 <TR BGCOLOR="white" CLASS="TableRowColor">
166 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
167 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
168 <TD><CODE><B><A HREF="../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)">serialize</A></B>(<A HREF="../../../com/google/gson/JsonSerializer.html" title="type parameter in JsonSerializer">T</A>&nbsp;src,
169 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
170 <A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A>&nbsp;context)</CODE>
171
172 <BR>
173 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during serialization when it encounters a field of the
174 specified type.</TD>
175 </TR>
176 </TABLE>
177 &nbsp;
178 <P>
179
180 <!-- ============ METHOD DETAIL ========== -->
181
182 <A NAME="method_detail"><!-- --></A>
183 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
184 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
185 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
186 <B>Method Detail</B></FONT></TH>
187 </TR>
188 </TABLE>
189
190 <A NAME="serialize(java.lang.Object,java.lang.reflect.Type,com.google.gson.JsonSerializationContext)"><!-- --></A><A NAME="serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><!-- --></A><H3>
191 serialize</H3>
192 <PRE>
193 <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>serialize</B>(<A HREF="../../../com/google/gson/JsonSerializer.html" title="type parameter in JsonSerializer">T</A>&nbsp;src,
194 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
195 <A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A>&nbsp;context)</PRE>
196 <DL>
197 <DD>Gson invokes this call-back method during serialization when it encounters a field of the
198 specified type.
199
200 <p>In the implementation of this call-back method, you should consider invoking
201 <A HREF="../../../com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object, java.lang.reflect.Type)"><CODE>JsonSerializationContext.serialize(Object, Type)</CODE></A> method to create JsonElements for any
202 non-trivial field of the <code>src</code> object. However, you should never invoke it on the
203 <code>src</code> object itself since that will cause an infinite loop (Gson will call your
204 call-back method again).</p>
205 <P>
206 <DD><DL>
207 <DT><B>Parameters:</B><DD><CODE>src</CODE> - the object that needs to be converted to Json.<DD><CODE>typeOfSrc</CODE> - the actual type (fully genericized version) of the source object.
208 <DT><B>Returns:</B><DD>a JsonElement corresponding to the specified object.</DL>
209 </DD>
210 </DL>
211 <!-- ========= END OF CLASS DATA ========= -->
212 <HR>
213
214
215 <!-- ======= START OF BOTTOM NAVBAR ====== -->
216 <A NAME="navbar_bottom"><!-- --></A>
217 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
218 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
219 <TR>
220 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
221 <A NAME="navbar_bottom_firstrow"><!-- --></A>
222 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
223 <TR ALIGN="center" VALIGN="top">
224 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
225 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
226 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
227 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonSerializer.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
228 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
229 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
230 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
231 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
232 </TR>
233 </TABLE>
234 </TD>
235 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
236 </EM>
237 </TD>
238 </TR>
239
240 <TR>
241 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
242 &nbsp;<A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
243 &nbsp;<A HREF="../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
244 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
245 <A HREF="../../../index.html?com/google/gson/JsonSerializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
246 &nbsp;<A HREF="JsonSerializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
247 &nbsp;<SCRIPT type="text/javascript">
248 <!--
249 if(window==top) {
250 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
251 }
252 //-->
253 </SCRIPT>
254 <NOSCRIPT>
255 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
256 </NOSCRIPT>
257
258
259 </FONT></TD>
260 </TR>
261 <TR>
262 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
263 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
264 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
265 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
266 </TR>
267 </TABLE>
268 <A NAME="skip-navbar_bottom"></A>
269 <!-- ======== END OF BOTTOM NAVBAR ======= -->
270
271 <HR>
272 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
273 </BODY>
274 </HTML>
+0
-369
gson/docs/javadocs/com/google/gson/JsonStreamParser.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonStreamParser (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonStreamParser (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonStreamParser.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonStreamParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonStreamParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonStreamParser</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonStreamParser</B>
97 </PRE>
98 <DL>
99 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</DD>
100 </DL>
101 <HR>
102 <DL>
103 <DT><PRE>public final class <B>JsonStreamParser</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</DL>
104 </PRE>
105
106 <P>
107 A streaming parser that allows reading of multiple <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s from the specified reader
108 asynchronously.
109
110 <p>This class is conditionally thread-safe (see Item 70, Effective Java second edition). To
111 properly use this class across multiple threads, you will need to add some external
112 synchronization. For example:
113
114 <pre>
115 JsonStreamParser parser = new JsonStreamParser("['first'] {'second':10} 'third'");
116 JsonElement element;
117 synchronized (parser) { // synchronize on an object shared by threads
118 if (parser.hasNext()) {
119 element = parser.next();
120 }
121 }
122 </pre>
123 <P>
124
125 <P>
126 <DL>
127 <DT><B>Since:</B></DT>
128 <DD>1.4</DD>
129 <DT><B>Author:</B></DT>
130 <DD>Inderjeet Singh, Joel Leitch</DD>
131 </DL>
132 <HR>
133
134 <P>
135
136 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
137
138 <A NAME="constructor_summary"><!-- --></A>
139 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
140 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
141 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
142 <B>Constructor Summary</B></FONT></TH>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD><CODE><B><A HREF="../../../com/google/gson/JsonStreamParser.html#JsonStreamParser(java.io.Reader)">JsonStreamParser</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;reader)</CODE>
146
147 <BR>
148 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
149 </TR>
150 <TR BGCOLOR="white" CLASS="TableRowColor">
151 <TD><CODE><B><A HREF="../../../com/google/gson/JsonStreamParser.html#JsonStreamParser(java.lang.String)">JsonStreamParser</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)</CODE>
152
153 <BR>
154 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
155 </TR>
156 </TABLE>
157 &nbsp;
158 <!-- ========== METHOD SUMMARY =========== -->
159
160 <A NAME="method_summary"><!-- --></A>
161 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
162 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
163 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
164 <B>Method Summary</B></FONT></TH>
165 </TR>
166 <TR BGCOLOR="white" CLASS="TableRowColor">
167 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
168 <CODE>&nbsp;boolean</CODE></FONT></TD>
169 <TD><CODE><B><A HREF="../../../com/google/gson/JsonStreamParser.html#hasNext()">hasNext</A></B>()</CODE>
170
171 <BR>
172 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if a <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> is available on the input for consumption</TD>
173 </TR>
174 <TR BGCOLOR="white" CLASS="TableRowColor">
175 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
176 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
177 <TD><CODE><B><A HREF="../../../com/google/gson/JsonStreamParser.html#next()">next</A></B>()</CODE>
178
179 <BR>
180 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next available <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> on the reader.</TD>
181 </TR>
182 <TR BGCOLOR="white" CLASS="TableRowColor">
183 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
184 <CODE>&nbsp;void</CODE></FONT></TD>
185 <TD><CODE><B><A HREF="../../../com/google/gson/JsonStreamParser.html#remove()">remove</A></B>()</CODE>
186
187 <BR>
188 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This optional <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util"><CODE>Iterator</CODE></A> method is not relevant for stream parsing and hence is not
189 implemented.</TD>
190 </TR>
191 </TABLE>
192 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
193 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
194 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
195 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
196 </TR>
197 <TR BGCOLOR="white" CLASS="TableRowColor">
198 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
199 </TR>
200 </TABLE>
201 &nbsp;
202 <P>
203
204 <!-- ========= CONSTRUCTOR DETAIL ======== -->
205
206 <A NAME="constructor_detail"><!-- --></A>
207 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
208 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
209 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
210 <B>Constructor Detail</B></FONT></TH>
211 </TR>
212 </TABLE>
213
214 <A NAME="JsonStreamParser(java.lang.String)"><!-- --></A><H3>
215 JsonStreamParser</H3>
216 <PRE>
217 public <B>JsonStreamParser</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)</PRE>
218 <DL>
219 <DL>
220 <DT><B>Parameters:</B><DD><CODE>json</CODE> - The string containing JSON elements concatenated to each other.<DT><B>Since:</B></DT>
221 <DD>1.4</DD>
222 </DL>
223 </DL>
224 <HR>
225
226 <A NAME="JsonStreamParser(java.io.Reader)"><!-- --></A><H3>
227 JsonStreamParser</H3>
228 <PRE>
229 public <B>JsonStreamParser</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;reader)</PRE>
230 <DL>
231 <DL>
232 <DT><B>Parameters:</B><DD><CODE>reader</CODE> - The data stream containing JSON elements concatenated to each other.<DT><B>Since:</B></DT>
233 <DD>1.4</DD>
234 </DL>
235 </DL>
236
237 <!-- ============ METHOD DETAIL ========== -->
238
239 <A NAME="method_detail"><!-- --></A>
240 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
241 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
242 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
243 <B>Method Detail</B></FONT></TH>
244 </TR>
245 </TABLE>
246
247 <A NAME="next()"><!-- --></A><H3>
248 next</H3>
249 <PRE>
250 public <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>next</B>()
251 throws <A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></PRE>
252 <DL>
253 <DD>Returns the next available <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> on the reader. Null if none available.
254 <P>
255 <DD><DL>
256 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true#next()" title="class or interface in java.util">next</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</CODE></DL>
257 </DD>
258 <DD><DL>
259
260 <DT><B>Returns:</B><DD>the next available <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> on the reader. Null if none available.
261 <DT><B>Throws:</B>
262 <DD><CODE><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></CODE> - if the incoming stream is malformed JSON.<DT><B>Since:</B></DT>
263 <DD>1.4</DD>
264 </DL>
265 </DD>
266 </DL>
267 <HR>
268
269 <A NAME="hasNext()"><!-- --></A><H3>
270 hasNext</H3>
271 <PRE>
272 public boolean <B>hasNext</B>()</PRE>
273 <DL>
274 <DD>Returns true if a <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> is available on the input for consumption
275 <P>
276 <DD><DL>
277 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true#hasNext()" title="class or interface in java.util">hasNext</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</CODE></DL>
278 </DD>
279 <DD><DL>
280
281 <DT><B>Returns:</B><DD>true if a <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> is available on the input, false otherwise<DT><B>Since:</B></DT>
282 <DD>1.4</DD>
283 </DL>
284 </DD>
285 </DL>
286 <HR>
287
288 <A NAME="remove()"><!-- --></A><H3>
289 remove</H3>
290 <PRE>
291 public void <B>remove</B>()</PRE>
292 <DL>
293 <DD>This optional <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util"><CODE>Iterator</CODE></A> method is not relevant for stream parsing and hence is not
294 implemented.
295 <P>
296 <DD><DL>
297 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true#remove()" title="class or interface in java.util">remove</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</CODE></DL>
298 </DD>
299 <DD><DL>
300 <DT><B>Since:</B></DT>
301 <DD>1.4</DD>
302 </DL>
303 </DD>
304 </DL>
305 <!-- ========= END OF CLASS DATA ========= -->
306 <HR>
307
308
309 <!-- ======= START OF BOTTOM NAVBAR ====== -->
310 <A NAME="navbar_bottom"><!-- --></A>
311 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
312 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
313 <TR>
314 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
315 <A NAME="navbar_bottom_firstrow"><!-- --></A>
316 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
317 <TR ALIGN="center" VALIGN="top">
318 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
319 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
320 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
321 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonStreamParser.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
322 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
323 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
324 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
325 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
326 </TR>
327 </TABLE>
328 </TD>
329 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
330 </EM>
331 </TD>
332 </TR>
333
334 <TR>
335 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
336 &nbsp;<A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
337 &nbsp;<A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
338 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
339 <A HREF="../../../index.html?com/google/gson/JsonStreamParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
340 &nbsp;<A HREF="JsonStreamParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
341 &nbsp;<SCRIPT type="text/javascript">
342 <!--
343 if(window==top) {
344 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
345 }
346 //-->
347 </SCRIPT>
348 <NOSCRIPT>
349 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
350 </NOSCRIPT>
351
352
353 </FONT></TD>
354 </TR>
355 <TR>
356 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
357 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
358 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
359 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
360 </TR>
361 </TABLE>
362 <A NAME="skip-navbar_bottom"></A>
363 <!-- ======== END OF BOTTOM NAVBAR ======= -->
364
365 <HR>
366 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
367 </BODY>
368 </HTML>
+0
-286
gson/docs/javadocs/com/google/gson/JsonSyntaxException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonSyntaxException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonSyntaxException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonSyntaxException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/JsonSyntaxException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonSyntaxException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class JsonSyntaxException</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">java.lang.Throwable</A>
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">java.lang.Exception</A>
98 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang">java.lang.RuntimeException</A>
99 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">com.google.gson.JsonParseException</A>
100 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.JsonSyntaxException</B>
101 </PRE>
102 <DL>
103 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A></DD>
104 </DL>
105 <HR>
106 <DL>
107 <DT><PRE>public final class <B>JsonSyntaxException</B><DT>extends <A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></DL>
108 </PRE>
109
110 <P>
111 This exception is raised when Gson attempts to read (or write) a malformed
112 JSON element.
113 <P>
114
115 <P>
116 <DL>
117 <DT><B>Author:</B></DT>
118 <DD>Inderjeet Singh, Joel Leitch</DD>
119 <DT><B>See Also:</B><DD><A HREF="../../../serialized-form.html#com.google.gson.JsonSyntaxException">Serialized Form</A></DL>
120 <HR>
121
122 <P>
123
124 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
125
126 <A NAME="constructor_summary"><!-- --></A>
127 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
128 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
129 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
130 <B>Constructor Summary</B></FONT></TH>
131 </TR>
132 <TR BGCOLOR="white" CLASS="TableRowColor">
133 <TD><CODE><B><A HREF="../../../com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.String)">JsonSyntaxException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
137 </TR>
138 <TR BGCOLOR="white" CLASS="TableRowColor">
139 <TD><CODE><B><A HREF="../../../com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.String, java.lang.Throwable)">JsonSyntaxException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
140 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</CODE>
141
142 <BR>
143 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
144 </TR>
145 <TR BGCOLOR="white" CLASS="TableRowColor">
146 <TD><CODE><B><A HREF="../../../com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.Throwable)">JsonSyntaxException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</CODE>
147
148 <BR>
149 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates exception with the specified cause.</TD>
150 </TR>
151 </TABLE>
152 &nbsp;
153 <!-- ========== METHOD SUMMARY =========== -->
154
155 <A NAME="method_summary"><!-- --></A>
156 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
157 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
158 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
159 <B>Method Summary</B></FONT></TH>
160 </TR>
161 </TABLE>
162 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Throwable"><!-- --></A>
163 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
164 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
165 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A></B></TH>
166 </TR>
167 <TR BGCOLOR="white" CLASS="TableRowColor">
168 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#fillInStackTrace()" title="class or interface in java.lang">fillInStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getCause()" title="class or interface in java.lang">getCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getLocalizedMessage()" title="class or interface in java.lang">getLocalizedMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getMessage()" title="class or interface in java.lang">getMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getStackTrace()" title="class or interface in java.lang">getStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#initCause(java.lang.Throwable)" title="class or interface in java.lang">initCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace()" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintStream)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintWriter)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#setStackTrace(java.lang.StackTraceElement[])" title="class or interface in java.lang">setStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE></TD>
169 </TR>
170 </TABLE>
171 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
172 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
173 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
174 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
175 </TR>
176 <TR BGCOLOR="white" CLASS="TableRowColor">
177 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
178 </TR>
179 </TABLE>
180 &nbsp;
181 <P>
182
183 <!-- ========= CONSTRUCTOR DETAIL ======== -->
184
185 <A NAME="constructor_detail"><!-- --></A>
186 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
187 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
188 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
189 <B>Constructor Detail</B></FONT></TH>
190 </TR>
191 </TABLE>
192
193 <A NAME="JsonSyntaxException(java.lang.String)"><!-- --></A><H3>
194 JsonSyntaxException</H3>
195 <PRE>
196 public <B>JsonSyntaxException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</PRE>
197 <DL>
198 </DL>
199 <HR>
200
201 <A NAME="JsonSyntaxException(java.lang.String, java.lang.Throwable)"><!-- --></A><H3>
202 JsonSyntaxException</H3>
203 <PRE>
204 public <B>JsonSyntaxException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
205 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</PRE>
206 <DL>
207 </DL>
208 <HR>
209
210 <A NAME="JsonSyntaxException(java.lang.Throwable)"><!-- --></A><H3>
211 JsonSyntaxException</H3>
212 <PRE>
213 public <B>JsonSyntaxException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;cause)</PRE>
214 <DL>
215 <DD>Creates exception with the specified cause. Consider using
216 <A HREF="../../../com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.String, java.lang.Throwable)"><CODE>JsonSyntaxException(String, Throwable)</CODE></A> instead if you can
217 describe what actually happened.
218 <P>
219 <DL>
220 <DT><B>Parameters:</B><DD><CODE>cause</CODE> - root exception that caused this exception to be thrown.</DL>
221 </DL>
222 <!-- ========= END OF CLASS DATA ========= -->
223 <HR>
224
225
226 <!-- ======= START OF BOTTOM NAVBAR ====== -->
227 <A NAME="navbar_bottom"><!-- --></A>
228 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
229 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
230 <TR>
231 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
232 <A NAME="navbar_bottom_firstrow"><!-- --></A>
233 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
234 <TR ALIGN="center" VALIGN="top">
235 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
236 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
237 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
238 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonSyntaxException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
239 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
240 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
241 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
242 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
243 </TR>
244 </TABLE>
245 </TD>
246 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
247 </EM>
248 </TD>
249 </TR>
250
251 <TR>
252 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
253 &nbsp;<A HREF="../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
254 &nbsp;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
255 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
256 <A HREF="../../../index.html?com/google/gson/JsonSyntaxException.html" target="_top"><B>FRAMES</B></A> &nbsp;
257 &nbsp;<A HREF="JsonSyntaxException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
258 &nbsp;<SCRIPT type="text/javascript">
259 <!--
260 if(window==top) {
261 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
262 }
263 //-->
264 </SCRIPT>
265 <NOSCRIPT>
266 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
267 </NOSCRIPT>
268
269
270 </FONT></TD>
271 </TR>
272 <TR>
273 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
274 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
275 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
276 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
277 </TR>
278 </TABLE>
279 <A NAME="skip-navbar_bottom"></A>
280 <!-- ======== END OF BOTTOM NAVBAR ======= -->
281
282 <HR>
283 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
284 </BODY>
285 </HTML>
+0
-365
gson/docs/javadocs/com/google/gson/LongSerializationPolicy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 LongSerializationPolicy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="LongSerializationPolicy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/LongSerializationPolicy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/LongSerializationPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="LongSerializationPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#enum_constant_summary">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#enum_constant_detail">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Enum LongSerializationPolicy</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">java.lang.Enum</A>&lt;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&gt;
97 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.LongSerializationPolicy</B>
98 </PRE>
99 <DL>
100 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&gt;</DD>
101 </DL>
102 <HR>
103 <DL>
104 <DT><PRE>public enum <B>LongSerializationPolicy</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</A>&lt;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&gt;</DL>
105 </PRE>
106
107 <P>
108 Defines the expected format for a <code>long</code> or <code>Long</code> type when its serialized.
109 <P>
110
111 <P>
112 <DL>
113 <DT><B>Since:</B></DT>
114 <DD>1.3</DD>
115 <DT><B>Author:</B></DT>
116 <DD>Inderjeet Singh, Joel Leitch</DD>
117 </DL>
118 <HR>
119
120 <P>
121 <!-- =========== ENUM CONSTANT SUMMARY =========== -->
122
123 <A NAME="enum_constant_summary"><!-- --></A>
124 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
125 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
126 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
127 <B>Enum Constant Summary</B></FONT></TH>
128 </TR>
129 <TR BGCOLOR="white" CLASS="TableRowColor">
130 <TD><CODE><B><A HREF="../../../com/google/gson/LongSerializationPolicy.html#DEFAULT">DEFAULT</A></B></CODE>
131
132 <BR>
133 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This is the "default" serialization policy that will output a <code>long</code> object as a JSON
134 number.</TD>
135 </TR>
136 <TR BGCOLOR="white" CLASS="TableRowColor">
137 <TD><CODE><B><A HREF="../../../com/google/gson/LongSerializationPolicy.html#STRING">STRING</A></B></CODE>
138
139 <BR>
140 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Serializes a long value as a quoted string.</TD>
141 </TR>
142 </TABLE>
143 &nbsp;
144 <!-- ========== METHOD SUMMARY =========== -->
145
146 <A NAME="method_summary"><!-- --></A>
147 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
148 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
149 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
150 <B>Method Summary</B></FONT></TH>
151 </TR>
152 <TR BGCOLOR="white" CLASS="TableRowColor">
153 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
154 <CODE>abstract &nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
155 <TD><CODE><B><A HREF="../../../com/google/gson/LongSerializationPolicy.html#serialize(java.lang.Long)">serialize</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</A>&nbsp;value)</CODE>
156
157 <BR>
158 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Serialize this <code>value</code> using this serialization policy.</TD>
159 </TR>
160 <TR BGCOLOR="white" CLASS="TableRowColor">
161 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
162 <CODE>static&nbsp;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A></CODE></FONT></TD>
163 <TD><CODE><B><A HREF="../../../com/google/gson/LongSerializationPolicy.html#valueOf(java.lang.String)">valueOf</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
164
165 <BR>
166 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the enum constant of this type with the specified name.</TD>
167 </TR>
168 <TR BGCOLOR="white" CLASS="TableRowColor">
169 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
170 <CODE>static&nbsp;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>[]</CODE></FONT></TD>
171 <TD><CODE><B><A HREF="../../../com/google/gson/LongSerializationPolicy.html#values()">values</A></B>()</CODE>
172
173 <BR>
174 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an array containing the constants of this enum type, in
175 the order they are declared.</TD>
176 </TR>
177 </TABLE>
178 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Enum"><!-- --></A>
179 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
180 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
181 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</A></B></TH>
182 </TR>
183 <TR BGCOLOR="white" CLASS="TableRowColor">
184 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Enum.html?is-external=true#valueOf(java.lang.Class, java.lang.String)" title="class or interface in java.lang">valueOf</A></CODE></TD>
185 </TR>
186 </TABLE>
187 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
188 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
189 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
190 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
191 </TR>
192 <TR BGCOLOR="white" CLASS="TableRowColor">
193 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
194 </TR>
195 </TABLE>
196 &nbsp;
197 <P>
198
199 <!-- ============ ENUM CONSTANT DETAIL =========== -->
200
201 <A NAME="enum_constant_detail"><!-- --></A>
202 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
203 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
204 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
205 <B>Enum Constant Detail</B></FONT></TH>
206 </TR>
207 </TABLE>
208
209 <A NAME="DEFAULT"><!-- --></A><H3>
210 DEFAULT</H3>
211 <PRE>
212 public static final <A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A> <B>DEFAULT</B></PRE>
213 <DL>
214 <DD>This is the "default" serialization policy that will output a <code>long</code> object as a JSON
215 number. For example, assume an object has a long field named "f" then the serialized output
216 would be:
217 <code>{"f":123}</code>.
218 <P>
219 <DL>
220 </DL>
221 </DL>
222 <HR>
223
224 <A NAME="STRING"><!-- --></A><H3>
225 STRING</H3>
226 <PRE>
227 public static final <A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A> <B>STRING</B></PRE>
228 <DL>
229 <DD>Serializes a long value as a quoted string. For example, assume an object has a long field
230 named "f" then the serialized output would be:
231 <code>{"f":"123"}</code>.
232 <P>
233 <DL>
234 </DL>
235 </DL>
236
237 <!-- ============ METHOD DETAIL ========== -->
238
239 <A NAME="method_detail"><!-- --></A>
240 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
241 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
242 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
243 <B>Method Detail</B></FONT></TH>
244 </TR>
245 </TABLE>
246
247 <A NAME="values()"><!-- --></A><H3>
248 values</H3>
249 <PRE>
250 public static <A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>[] <B>values</B>()</PRE>
251 <DL>
252 <DD>Returns an array containing the constants of this enum type, in
253 the order they are declared. This method may be used to iterate
254 over the constants as follows:
255 <pre>
256 for (LongSerializationPolicy c : LongSerializationPolicy.values())
257 &nbsp; System.out.println(c);
258 </pre>
259 <P>
260 <DD><DL>
261
262 <DT><B>Returns:</B><DD>an array containing the constants of this enum type, in
263 the order they are declared</DL>
264 </DD>
265 </DL>
266 <HR>
267
268 <A NAME="valueOf(java.lang.String)"><!-- --></A><H3>
269 valueOf</H3>
270 <PRE>
271 public static <A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A> <B>valueOf</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</PRE>
272 <DL>
273 <DD>Returns the enum constant of this type with the specified name.
274 The string must match <I>exactly</I> an identifier used to declare an
275 enum constant in this type. (Extraneous whitespace characters are
276 not permitted.)
277 <P>
278 <DD><DL>
279 <DT><B>Parameters:</B><DD><CODE>name</CODE> - the name of the enum constant to be returned.
280 <DT><B>Returns:</B><DD>the enum constant with the specified name
281 <DT><B>Throws:</B>
282 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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
283 with the specified name
284 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if the argument is null</DL>
285 </DD>
286 </DL>
287 <HR>
288
289 <A NAME="serialize(java.lang.Long)"><!-- --></A><H3>
290 serialize</H3>
291 <PRE>
292 public abstract <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>serialize</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</A>&nbsp;value)</PRE>
293 <DL>
294 <DD>Serialize this <code>value</code> using this serialization policy.
295 <P>
296 <DD><DL>
297 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the long value to be serialized into a <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>
298 <DT><B>Returns:</B><DD>the serialized version of <code>value</code></DL>
299 </DD>
300 </DL>
301 <!-- ========= END OF CLASS DATA ========= -->
302 <HR>
303
304
305 <!-- ======= START OF BOTTOM NAVBAR ====== -->
306 <A NAME="navbar_bottom"><!-- --></A>
307 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
308 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
309 <TR>
310 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
311 <A NAME="navbar_bottom_firstrow"><!-- --></A>
312 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
313 <TR ALIGN="center" VALIGN="top">
314 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
315 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
316 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
317 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/LongSerializationPolicy.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
318 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
319 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
320 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
321 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
322 </TR>
323 </TABLE>
324 </TD>
325 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
326 </EM>
327 </TD>
328 </TR>
329
330 <TR>
331 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
332 &nbsp;<A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
333 &nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
334 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
335 <A HREF="../../../index.html?com/google/gson/LongSerializationPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
336 &nbsp;<A HREF="LongSerializationPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
337 &nbsp;<SCRIPT type="text/javascript">
338 <!--
339 if(window==top) {
340 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
341 }
342 //-->
343 </SCRIPT>
344 <NOSCRIPT>
345 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
346 </NOSCRIPT>
347
348
349 </FONT></TD>
350 </TR>
351 <TR>
352 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
353 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#enum_constant_summary">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
354 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
355 DETAIL:&nbsp;<A HREF="#enum_constant_detail">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
356 </TR>
357 </TABLE>
358 <A NAME="skip-navbar_bottom"></A>
359 <!-- ======== END OF BOTTOM NAVBAR ======= -->
360
361 <HR>
362 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
363 </BODY>
364 </HTML>
+0
-574
gson/docs/javadocs/com/google/gson/TypeAdapter.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 TypeAdapter (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="TypeAdapter (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/TypeAdapter.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/TypeAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="TypeAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Class TypeAdapter&lt;T&gt;</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.TypeAdapter&lt;T&gt;</B>
97 </PRE>
98 <HR>
99 <DL>
100 <DT><PRE>public abstract class <B>TypeAdapter&lt;T&gt;</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101 </PRE>
102
103 <P>
104 Converts Java objects to and from JSON.
105
106 <h3>Defining a type's JSON form</h3>
107 By default Gson converts application classes to JSON using its built-in type
108 adapters. If Gson's default JSON conversion isn't appropriate for a type,
109 extend this class to customize the conversion. Here's an example of a type
110 adapter for an (X,Y) coordinate point: <pre> <code>public class PointAdapter extends TypeAdapter&lt;Point&gt; {
111 public Point read(JsonReader reader) throws IOException {
112 if (reader.peek() == JsonToken.NULL) {
113 reader.nextNull();
114 return null;
115 }
116 String xy = reader.nextString();
117 String[] parts = xy.split(",");
118 int x = Integer.parseInt(parts[0]);
119 int y = Integer.parseInt(parts[1]);
120 return new Point(x, y);
121 }
122 public void write(JsonWriter writer, Point value) throws IOException {
123 if (value == null) {
124 writer.nullValue();
125 return;
126 }
127 String xy = value.getX() + "," + value.getY();
128 writer.value(xy);
129 }
130 }</code></pre>
131 With this type adapter installed, Gson will convert <code>Points</code> to JSON as
132 strings like <code>"5,8"</code> rather than objects like <code>{"x":5,"y":8}</code>. In
133 this case the type adapter binds a rich Java class to a compact JSON value.
134
135 <p>The <A HREF="../../../com/google/gson/TypeAdapter.html#read(com.google.gson.stream.JsonReader)"><CODE>read()</CODE></A> method must read exactly one value
136 and <A HREF="../../../com/google/gson/TypeAdapter.html#write(com.google.gson.stream.JsonWriter, T)"><CODE>write()</CODE></A> must write exactly one value.
137 For primitive types this is means readers should make exactly one call to
138 <code>nextBoolean()</code>, <code>nextDouble()</code>, <code>nextInt()</code>, <code>nextLong()</code>, <code>nextString()</code> or <code>nextNull()</code>. Writers should make
139 exactly one call to one of <code>value()</code> or <code>nullValue()</code>.
140 For arrays, type adapters should start with a call to <code>beginArray()</code>,
141 convert all elements, and finish with a call to <code>endArray()</code>. For
142 objects, they should start with <code>beginObject()</code>, convert the object,
143 and finish with <code>endObject()</code>. Failing to convert a value or converting
144 too many values may cause the application to crash.
145
146 <p>Type adapters should be prepared to read null from the stream and write it
147 to the stream. Alternatively, they should use <A HREF="../../../com/google/gson/TypeAdapter.html#nullSafe()"><CODE>nullSafe()</CODE></A> method while
148 registering the type adapter with Gson. If your <code>Gson</code> instance
149 has been configured to <A HREF="../../../com/google/gson/GsonBuilder.html#serializeNulls()"><CODE>GsonBuilder.serializeNulls()</CODE></A>, these nulls will be
150 written to the final document. Otherwise the value (and the corresponding name
151 when writing to a JSON object) will be omitted automatically. In either case
152 your type adapter must handle null.
153
154 <p>To use a custom type adapter with Gson, you must <i>register</i> it with a
155 <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A>: <pre> <code>GsonBuilder builder = new GsonBuilder();
156 builder.registerTypeAdapter(Point.class, new PointAdapter());
157 // if PointAdapter didn't check for nulls in its read/write methods, you should instead use
158 // builder.registerTypeAdapter(Point.class, new PointAdapter().nullSafe());
159 ...
160 Gson gson = builder.create();
161 </code></pre>
162 <P>
163
164 <P>
165 <DL>
166 <DT><B>Since:</B></DT>
167 <DD>2.1</DD>
168 </DL>
169 <HR>
170
171 <P>
172
173 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
174
175 <A NAME="constructor_summary"><!-- --></A>
176 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
177 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
178 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
179 <B>Constructor Summary</B></FONT></TH>
180 </TR>
181 <TR BGCOLOR="white" CLASS="TableRowColor">
182 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#TypeAdapter()">TypeAdapter</A></B>()</CODE>
183
184 <BR>
185 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
186 </TR>
187 </TABLE>
188 &nbsp;
189 <!-- ========== METHOD SUMMARY =========== -->
190
191 <A NAME="method_summary"><!-- --></A>
192 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
193 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
194 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
195 <B>Method Summary</B></FONT></TH>
196 </TR>
197 <TR BGCOLOR="white" CLASS="TableRowColor">
198 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
199 <CODE>&nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A></CODE></FONT></TD>
200 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#fromJson(java.io.Reader)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;in)</CODE>
201
202 <BR>
203 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts the JSON document in <code>in</code> to a Java object.</TD>
204 </TR>
205 <TR BGCOLOR="white" CLASS="TableRowColor">
206 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
207 <CODE>&nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A></CODE></FONT></TD>
208 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#fromJson(java.lang.String)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)</CODE>
209
210 <BR>
211 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts the JSON document in <code>json</code> to a Java object.</TD>
212 </TR>
213 <TR BGCOLOR="white" CLASS="TableRowColor">
214 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
215 <CODE>&nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A></CODE></FONT></TD>
216 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#fromJsonTree(com.google.gson.JsonElement)">fromJsonTree</A></B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonTree)</CODE>
217
218 <BR>
219 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts <code>jsonTree</code> to a Java object.</TD>
220 </TR>
221 <TR BGCOLOR="white" CLASS="TableRowColor">
222 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
223 <CODE>&nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&gt;</CODE></FONT></TD>
224 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#nullSafe()">nullSafe</A></B>()</CODE>
225
226 <BR>
227 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This wrapper method is used to make a type adapter null tolerant.</TD>
228 </TR>
229 <TR BGCOLOR="white" CLASS="TableRowColor">
230 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
231 <CODE>abstract &nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A></CODE></FONT></TD>
232 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#read(com.google.gson.stream.JsonReader)">read</A></B>(<A HREF="../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;in)</CODE>
233
234 <BR>
235 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads one JSON value (an array, object, string, number, boolean or null)
236 and converts it to a Java object.</TD>
237 </TR>
238 <TR BGCOLOR="white" CLASS="TableRowColor">
239 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
240 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
241 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#toJson(T)">toJson</A></B>(<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</CODE>
242
243 <BR>
244 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts <code>value</code> to a JSON document.</TD>
245 </TR>
246 <TR BGCOLOR="white" CLASS="TableRowColor">
247 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
248 <CODE>&nbsp;void</CODE></FONT></TD>
249 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#toJson(java.io.Writer, T)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</A>&nbsp;out,
250 <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</CODE>
251
252 <BR>
253 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts <code>value</code> to a JSON document and writes it to <code>out</code>.</TD>
254 </TR>
255 <TR BGCOLOR="white" CLASS="TableRowColor">
256 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
257 <CODE>&nbsp;<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
258 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#toJsonTree(T)">toJsonTree</A></B>(<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</CODE>
259
260 <BR>
261 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts <code>value</code> to a JSON tree.</TD>
262 </TR>
263 <TR BGCOLOR="white" CLASS="TableRowColor">
264 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
265 <CODE>abstract &nbsp;void</CODE></FONT></TD>
266 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapter.html#write(com.google.gson.stream.JsonWriter, T)">write</A></B>(<A HREF="../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;out,
267 <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</CODE>
268
269 <BR>
270 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes one JSON value (an array, object, string, number, boolean or null)
271 for <code>value</code>.</TD>
272 </TR>
273 </TABLE>
274 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
275 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
276 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
277 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
278 </TR>
279 <TR BGCOLOR="white" CLASS="TableRowColor">
280 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
281 </TR>
282 </TABLE>
283 &nbsp;
284 <P>
285
286 <!-- ========= CONSTRUCTOR DETAIL ======== -->
287
288 <A NAME="constructor_detail"><!-- --></A>
289 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
290 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
291 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
292 <B>Constructor Detail</B></FONT></TH>
293 </TR>
294 </TABLE>
295
296 <A NAME="TypeAdapter()"><!-- --></A><H3>
297 TypeAdapter</H3>
298 <PRE>
299 public <B>TypeAdapter</B>()</PRE>
300 <DL>
301 </DL>
302
303 <!-- ============ METHOD DETAIL ========== -->
304
305 <A NAME="method_detail"><!-- --></A>
306 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
307 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
308 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
309 <B>Method Detail</B></FONT></TH>
310 </TR>
311 </TABLE>
312
313 <A NAME="write(com.google.gson.stream.JsonWriter,java.lang.Object)"><!-- --></A><A NAME="write(com.google.gson.stream.JsonWriter, T)"><!-- --></A><H3>
314 write</H3>
315 <PRE>
316 public abstract void <B>write</B>(<A HREF="../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;out,
317 <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)
318 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
319 <DL>
320 <DD>Writes one JSON value (an array, object, string, number, boolean or null)
321 for <code>value</code>.
322 <P>
323 <DD><DL>
324 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the Java object to write. May be null.
325 <DT><B>Throws:</B>
326 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
327 </DD>
328 </DL>
329 <HR>
330
331 <A NAME="toJson(java.io.Writer,java.lang.Object)"><!-- --></A><A NAME="toJson(java.io.Writer, T)"><!-- --></A><H3>
332 toJson</H3>
333 <PRE>
334 public final void <B>toJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</A>&nbsp;out,
335 <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)
336 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
337 <DL>
338 <DD>Converts <code>value</code> to a JSON document and writes it to <code>out</code>.
339 Unlike Gson's similar <A HREF="../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, java.lang.Appendable)"><CODE>toJson</CODE></A>
340 method, this write is strict. Create a <A HREF="../../../com/google/gson/stream/JsonWriter.html#setLenient(boolean)"><CODE>lenient</CODE></A> <code>JsonWriter</code> and call
341 <A HREF="../../../com/google/gson/TypeAdapter.html#write(com.google.gson.stream.JsonWriter, T)"><CODE>write(com.google.gson.stream.JsonWriter, Object)</CODE></A> for lenient
342 writing.
343 <P>
344 <DD><DL>
345 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the Java object to convert. May be null.
346 <DT><B>Throws:</B>
347 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE><DT><B>Since:</B></DT>
348 <DD>2.2</DD>
349 </DL>
350 </DD>
351 </DL>
352 <HR>
353
354 <A NAME="nullSafe()"><!-- --></A><H3>
355 nullSafe</H3>
356 <PRE>
357 public final <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&gt; <B>nullSafe</B>()</PRE>
358 <DL>
359 <DD>This wrapper method is used to make a type adapter null tolerant. In general, a
360 type adapter is required to handle nulls in write and read methods. Here is how this
361 is typically done:<br>
362 <pre> <code>Gson gson = new GsonBuilder().registerTypeAdapter(Foo.class,
363 new TypeAdapter&lt;Foo&gt;() {
364 public Foo read(JsonReader in) throws IOException {
365 if (in.peek() == JsonToken.NULL) {
366 in.nextNull();
367 return null;
368 }
369 // read a Foo from in and return it
370 }
371 public void write(JsonWriter out, Foo src) throws IOException {
372 if (src == null) {
373 out.nullValue();
374 return;
375 }
376 // write src as JSON to out
377 }
378 }).create();
379 </code></pre>
380 You can avoid this boilerplate handling of nulls by wrapping your type adapter with
381 this method. Here is how we will rewrite the above example:
382 <pre> <code>Gson gson = new GsonBuilder().registerTypeAdapter(Foo.class,
383 new TypeAdapter&lt;Foo&gt;() {
384 public Foo read(JsonReader in) throws IOException {
385 // read a Foo from in and return it
386 }
387 public void write(JsonWriter out, Foo src) throws IOException {
388 // write src as JSON to out
389 }
390 }.nullSafe()).create();
391 </code></pre>
392 Note that we didn't need to check for nulls in our type adapter after we used nullSafe.
393 <P>
394 <DD><DL>
395 </DL>
396 </DD>
397 </DL>
398 <HR>
399
400 <A NAME="toJson(java.lang.Object)"><!-- --></A><A NAME="toJson(T)"><!-- --></A><H3>
401 toJson</H3>
402 <PRE>
403 public final <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toJson</B>(<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)
404 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
405 <DL>
406 <DD>Converts <code>value</code> to a JSON document. Unlike Gson's similar <A HREF="../../../com/google/gson/Gson.html#toJson(java.lang.Object)"><CODE>toJson</CODE></A> method, this write is strict. Create a <A HREF="../../../com/google/gson/stream/JsonWriter.html#setLenient(boolean)"><CODE>lenient</CODE></A> <code>JsonWriter</code> and call
407 <A HREF="../../../com/google/gson/TypeAdapter.html#write(com.google.gson.stream.JsonWriter, T)"><CODE>write(com.google.gson.stream.JsonWriter, Object)</CODE></A> for lenient
408 writing.
409 <P>
410 <DD><DL>
411 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the Java object to convert. May be null.
412 <DT><B>Throws:</B>
413 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE><DT><B>Since:</B></DT>
414 <DD>2.2</DD>
415 </DL>
416 </DD>
417 </DL>
418 <HR>
419
420 <A NAME="toJsonTree(java.lang.Object)"><!-- --></A><A NAME="toJsonTree(T)"><!-- --></A><H3>
421 toJsonTree</H3>
422 <PRE>
423 public final <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> <B>toJsonTree</B>(<A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</PRE>
424 <DL>
425 <DD>Converts <code>value</code> to a JSON tree.
426 <P>
427 <DD><DL>
428 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the Java object to convert. May be null.
429 <DT><B>Returns:</B><DD>the converted JSON tree. May be <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.<DT><B>Since:</B></DT>
430 <DD>2.2</DD>
431 </DL>
432 </DD>
433 </DL>
434 <HR>
435
436 <A NAME="read(com.google.gson.stream.JsonReader)"><!-- --></A><H3>
437 read</H3>
438 <PRE>
439 public abstract <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A> <B>read</B>(<A HREF="../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;in)
440 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
441 <DL>
442 <DD>Reads one JSON value (an array, object, string, number, boolean or null)
443 and converts it to a Java object. Returns the converted object.
444 <P>
445 <DD><DL>
446
447 <DT><B>Returns:</B><DD>the converted Java object. May be null.
448 <DT><B>Throws:</B>
449 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
450 </DD>
451 </DL>
452 <HR>
453
454 <A NAME="fromJson(java.io.Reader)"><!-- --></A><H3>
455 fromJson</H3>
456 <PRE>
457 public final <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A> <B>fromJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;in)
458 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
459 <DL>
460 <DD>Converts the JSON document in <code>in</code> to a Java object. Unlike Gson's
461 similar <A HREF="../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)"><CODE>fromJson</CODE></A> method, this
462 read is strict. Create a <A HREF="../../../com/google/gson/stream/JsonReader.html#setLenient(boolean)"><CODE>lenient</CODE></A>
463 <code>JsonReader</code> and call <A HREF="../../../com/google/gson/TypeAdapter.html#read(com.google.gson.stream.JsonReader)"><CODE>read(JsonReader)</CODE></A> for lenient reading.
464 <P>
465 <DD><DL>
466
467 <DT><B>Returns:</B><DD>the converted Java object. May be null.
468 <DT><B>Throws:</B>
469 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE><DT><B>Since:</B></DT>
470 <DD>2.2</DD>
471 </DL>
472 </DD>
473 </DL>
474 <HR>
475
476 <A NAME="fromJson(java.lang.String)"><!-- --></A><H3>
477 fromJson</H3>
478 <PRE>
479 public final <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A> <B>fromJson</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)
480 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
481 <DL>
482 <DD>Converts the JSON document in <code>json</code> to a Java object. Unlike Gson's
483 similar <A HREF="../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)"><CODE>fromJson</CODE></A> method, this read is
484 strict. Create a <A HREF="../../../com/google/gson/stream/JsonReader.html#setLenient(boolean)"><CODE>lenient</CODE></A> <code>JsonReader</code> and call <A HREF="../../../com/google/gson/TypeAdapter.html#read(com.google.gson.stream.JsonReader)"><CODE>read(JsonReader)</CODE></A> for lenient reading.
485 <P>
486 <DD><DL>
487
488 <DT><B>Returns:</B><DD>the converted Java object. May be null.
489 <DT><B>Throws:</B>
490 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE><DT><B>Since:</B></DT>
491 <DD>2.2</DD>
492 </DL>
493 </DD>
494 </DL>
495 <HR>
496
497 <A NAME="fromJsonTree(com.google.gson.JsonElement)"><!-- --></A><H3>
498 fromJsonTree</H3>
499 <PRE>
500 public final <A HREF="../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A> <B>fromJsonTree</B>(<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonTree)</PRE>
501 <DL>
502 <DD>Converts <code>jsonTree</code> to a Java object.
503 <P>
504 <DD><DL>
505 <DT><B>Parameters:</B><DD><CODE>jsonTree</CODE> - the Java object to convert. May be <A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.<DT><B>Since:</B></DT>
506 <DD>2.2</DD>
507 </DL>
508 </DD>
509 </DL>
510 <!-- ========= END OF CLASS DATA ========= -->
511 <HR>
512
513
514 <!-- ======= START OF BOTTOM NAVBAR ====== -->
515 <A NAME="navbar_bottom"><!-- --></A>
516 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
517 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
518 <TR>
519 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
520 <A NAME="navbar_bottom_firstrow"><!-- --></A>
521 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
522 <TR ALIGN="center" VALIGN="top">
523 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
524 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
525 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
526 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/TypeAdapter.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
527 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
528 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
529 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
530 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
531 </TR>
532 </TABLE>
533 </TD>
534 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
535 </EM>
536 </TD>
537 </TR>
538
539 <TR>
540 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
541 &nbsp;<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
542 &nbsp;<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><B>NEXT CLASS</B></A></FONT></TD>
543 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
544 <A HREF="../../../index.html?com/google/gson/TypeAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
545 &nbsp;<A HREF="TypeAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
546 &nbsp;<SCRIPT type="text/javascript">
547 <!--
548 if(window==top) {
549 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
550 }
551 //-->
552 </SCRIPT>
553 <NOSCRIPT>
554 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
555 </NOSCRIPT>
556
557
558 </FONT></TD>
559 </TR>
560 <TR>
561 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
562 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
563 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
564 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
565 </TR>
566 </TABLE>
567 <A NAME="skip-navbar_bottom"></A>
568 <!-- ======== END OF BOTTOM NAVBAR ======= -->
569
570 <HR>
571 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
572 </BODY>
573 </HTML>
+0
-354
gson/docs/javadocs/com/google/gson/TypeAdapterFactory.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 TypeAdapterFactory (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="TypeAdapterFactory (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/TypeAdapterFactory.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;NEXT CLASS</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/TypeAdapterFactory.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="TypeAdapterFactory.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson</FONT>
92 <BR>
93 Interface TypeAdapterFactory</H2>
94 <HR>
95 <DL>
96 <DT><PRE>public interface <B>TypeAdapterFactory</B></DL>
97 </PRE>
98
99 <P>
100 Creates type adapters for set of related types. Type adapter factories are
101 most useful when several types share similar structure in their JSON form.
102
103 <h3>Example: Converting enums to lowercase</h3>
104 In this example, we implement a factory that creates type adapters for all
105 enums. The type adapters will write enums in lowercase, despite the fact
106 that they're defined in <code>CONSTANT_CASE</code> in the corresponding Java
107 model: <pre> <code>public class LowercaseEnumTypeAdapterFactory implements TypeAdapterFactory {
108 public &lt;T&gt; TypeAdapter&lt;T&gt; create(Gson gson, TypeToken&lt;T&gt; type) {
109 Class&lt;T&gt; rawType = (Class&lt;T&gt;) type.getRawType();
110 if (!rawType.isEnum()) {
111 return null;
112 }
113
114 final Map&lt;String, T&gt; lowercaseToConstant = new HashMap&lt;String, T&gt;();
115 for (T constant : rawType.getEnumConstants()) {
116 lowercaseToConstant.put(toLowercase(constant), constant);
117 }
118
119 return new TypeAdapter&lt;T&gt;() {
120 public void write(JsonWriter out, T value) throws IOException {
121 if (value == null) {
122 out.nullValue();
123 } else {
124 out.value(toLowercase(value));
125 }
126 }
127
128 public T read(JsonReader reader) throws IOException {
129 if (reader.peek() == JsonToken.NULL) {
130 reader.nextNull();
131 return null;
132 } else {
133 return lowercaseToConstant.get(reader.nextString());
134 }
135 }
136 };
137 }
138
139 private String toLowercase(Object o) {
140 return o.toString().toLowerCase(Locale.US);
141 }
142 }
143 </code></pre>
144
145 <p>Type adapter factories select which types they provide type adapters
146 for. If a factory cannot support a given type, it must return null when
147 that type is passed to <A HREF="../../../com/google/gson/TypeAdapterFactory.html#create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)"><CODE>create(com.google.gson.Gson, com.google.gson.reflect.TypeToken<T>)</CODE></A>. Factories should expect <code>create()</code> to be called on them for many types and should return null for
148 most of those types. In the above example the factory returns null for
149 calls to <code>create()</code> where <code>type</code> is not an enum.
150
151 <p>A factory is typically called once per type, but the returned type
152 adapter may be used many times. It is most efficient to do expensive work
153 like reflection in <code>create()</code> so that the type adapter's <code>read()</code> and <code>write()</code> methods can be very fast. In this example the
154 mapping from lowercase name to enum value is computed eagerly.
155
156 <p>As with type adapters, factories must be <i>registered</i> with a <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A> for them to take effect: <pre> <code>GsonBuilder builder = new GsonBuilder();
157 builder.registerTypeAdapterFactory(new LowercaseEnumTypeAdapterFactory());
158 ...
159 Gson gson = builder.create();
160 </code></pre>
161 If multiple factories support the same type, the factory registered earlier
162 takes precedence.
163
164 <h3>Example: composing other type adapters</h3>
165 In this example we implement a factory for Guava's <code>Multiset</code>
166 collection type. The factory can be used to create type adapters for
167 multisets of any element type: the type adapter for <code>Multiset&lt;String&gt;</code> is different from the type adapter for <code>Multiset&lt;URL&gt;</code>.
168
169 <p>The type adapter <i>delegates</i> to another type adapter for the
170 multiset elements. It figures out the element type by reflecting on the
171 multiset's type token. A <code>Gson</code> is passed in to <code>create</code> for
172 just this purpose: <pre> <code>public class MultisetTypeAdapterFactory implements TypeAdapterFactory {
173 public &lt;T&gt; TypeAdapter&lt;T&gt; create(Gson gson, TypeToken&lt;T&gt; typeToken) {
174 Type type = typeToken.getType();
175 if (typeToken.getRawType() != Multiset.class
176 || !(type instanceof ParameterizedType)) {
177 return null;
178 }
179
180 Type elementType = ((ParameterizedType) type).getActualTypeArguments()[0];
181 TypeAdapter&lt;?&gt; elementAdapter = gson.getAdapter(TypeToken.get(elementType));
182 return (TypeAdapter&lt;T&gt;) newMultisetAdapter(elementAdapter);
183 }
184
185 private &lt;E&gt; TypeAdapter&lt;Multiset&lt;E&gt;&gt; newMultisetAdapter(
186 final TypeAdapter&lt;E&gt; elementAdapter) {
187 return new TypeAdapter&lt;Multiset&lt;E&gt;&gt;() {
188 public void write(JsonWriter out, Multiset&lt;E&gt; value) throws IOException {
189 if (value == null) {
190 out.nullValue();
191 return;
192 }
193
194 out.beginArray();
195 for (Multiset.Entry&lt;E&gt; entry : value.entrySet()) {
196 out.value(entry.getCount());
197 elementAdapter.write(out, entry.getElement());
198 }
199 out.endArray();
200 }
201
202 public Multiset&lt;E&gt; read(JsonReader in) throws IOException {
203 if (in.peek() == JsonToken.NULL) {
204 in.nextNull();
205 return null;
206 }
207
208 Multiset&lt;E&gt; result = LinkedHashMultiset.create();
209 in.beginArray();
210 while (in.hasNext()) {
211 int count = in.nextInt();
212 E element = elementAdapter.read(in);
213 result.add(element, count);
214 }
215 in.endArray();
216 return result;
217 }
218 };
219 }
220 }
221 </code></pre>
222 Delegating from one type adapter to another is extremely powerful; it's
223 the foundation of how Gson converts Java objects and collections. Whenever
224 possible your factory should retrieve its delegate type adapter in the
225 <code>create()</code> method; this ensures potentially-expensive type adapter
226 creation happens only once.
227 <P>
228
229 <P>
230 <DL>
231 <DT><B>Since:</B></DT>
232 <DD>2.1</DD>
233 </DL>
234 <HR>
235
236 <P>
237
238 <!-- ========== METHOD SUMMARY =========== -->
239
240 <A NAME="method_summary"><!-- --></A>
241 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
242 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
243 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
244 <B>Method Summary</B></FONT></TH>
245 </TR>
246 <TR BGCOLOR="white" CLASS="TableRowColor">
247 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
248 <CODE>
249 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
250 <TR ALIGN="right" VALIGN="">
251 <TD NOWRAP><FONT SIZE="-1">
252 <CODE>&lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
253 </TR>
254 </TABLE>
255 </CODE></FONT></TD>
256 <TD><CODE><B><A HREF="../../../com/google/gson/TypeAdapterFactory.html#create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)">create</A></B>(<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>&nbsp;gson,
257 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
258
259 <BR>
260 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a type adapter for <code>type</code>, or null if this factory doesn't
261 support <code>type</code>.</TD>
262 </TR>
263 </TABLE>
264 &nbsp;
265 <P>
266
267 <!-- ============ METHOD DETAIL ========== -->
268
269 <A NAME="method_detail"><!-- --></A>
270 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
271 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
272 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
273 <B>Method Detail</B></FONT></TH>
274 </TR>
275 </TABLE>
276
277 <A NAME="create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)"><!-- --></A><H3>
278 create</H3>
279 <PRE>
280 &lt;T&gt; <A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt; <B>create</B>(<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>&nbsp;gson,
281 <A HREF="../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</PRE>
282 <DL>
283 <DD>Returns a type adapter for <code>type</code>, or null if this factory doesn't
284 support <code>type</code>.
285 <P>
286 <DD><DL>
287 </DL>
288 </DD>
289 </DL>
290 <!-- ========= END OF CLASS DATA ========= -->
291 <HR>
292
293
294 <!-- ======= START OF BOTTOM NAVBAR ====== -->
295 <A NAME="navbar_bottom"><!-- --></A>
296 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
297 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
298 <TR>
299 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
300 <A NAME="navbar_bottom_firstrow"><!-- --></A>
301 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
302 <TR ALIGN="center" VALIGN="top">
303 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
304 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
305 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
306 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/TypeAdapterFactory.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
307 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
308 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
309 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
310 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
311 </TR>
312 </TABLE>
313 </TD>
314 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
315 </EM>
316 </TD>
317 </TR>
318
319 <TR>
320 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
321 &nbsp;<A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>PREV CLASS</B></A>&nbsp;
322 &nbsp;NEXT CLASS</FONT></TD>
323 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
324 <A HREF="../../../index.html?com/google/gson/TypeAdapterFactory.html" target="_top"><B>FRAMES</B></A> &nbsp;
325 &nbsp;<A HREF="TypeAdapterFactory.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
326 &nbsp;<SCRIPT type="text/javascript">
327 <!--
328 if(window==top) {
329 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
330 }
331 //-->
332 </SCRIPT>
333 <NOSCRIPT>
334 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
335 </NOSCRIPT>
336
337
338 </FONT></TD>
339 </TR>
340 <TR>
341 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
342 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
343 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
344 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;CONSTR&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
345 </TR>
346 </TABLE>
347 <A NAME="skip-navbar_bottom"></A>
348 <!-- ======== END OF BOTTOM NAVBAR ======= -->
349
350 <HR>
351 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
352 </BODY>
353 </HTML>
+0
-277
gson/docs/javadocs/com/google/gson/annotations/Expose.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Expose (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Expose (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Expose.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV CLASS&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/Expose.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Expose.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;REQUIRED&nbsp;|&nbsp;<A HREF="#annotation_type_optional_element_summary">OPTIONAL</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.annotations</FONT>
92 <BR>
93 Annotation Type Expose</H2>
94 <HR>
95 <DL>
96 <DT><PRE><FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</A>)
97 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</A>)
98 </FONT>public @interface <B>Expose</B></DL>
99 </PRE>
100
101 <P>
102 An annotation that indicates this member should be exposed for JSON
103 serialization or deserialization.
104
105 <p>This annotation has no effect unless you build <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A>
106 with a <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A> and invoke
107 <A HREF="../../../../com/google/gson/GsonBuilder.html#excludeFieldsWithoutExposeAnnotation()"><CODE>GsonBuilder.excludeFieldsWithoutExposeAnnotation()</CODE></A>
108 method.</p>
109
110 <p>Here is an example of how this annotation is meant to be used:
111 <p><pre>
112 public class User {
113 &#64Expose private String firstName;
114 &#64Expose(serialize = false) private String lastName;
115 &#64Expose (serialize = false, deserialize = false) private String emailAddress;
116 private String password;
117 }
118 </pre></p>
119 If you created Gson with <code>new Gson()</code>, the <code>toJson()</code> and <code>fromJson()</code>
120 methods will use the <code>password</code> field along-with <code>firstName</code>, <code>lastName</code>,
121 and <code>emailAddress</code> for serialization and deserialization. However, if you created Gson
122 with <code>Gson gson = new GsonBuilder().excludeFieldsWithoutExposeAnnotation().create()</code>
123 then the <code>toJson()</code> and <code>fromJson()</code> methods of Gson will exclude the
124 <code>password</code> field. This is because the <code>password</code> field is not marked with the
125 <code>@Expose</code> annotation. Gson will also exclude <code>lastName</code> and <code>emailAddress</code>
126 from serialization since <code>serialize</code> is set to <code>false</code>. Similarly, Gson will
127 exclude <code>emailAddress</code> from deserialization since <code>deserialize</code> is set to false.
128
129 <p>Note that another way to achieve the same effect would have been to just mark the
130 <code>password</code> field as <code>transient</code>, and Gson would have excluded it even with default
131 settings. The <code>@Expose</code> annotation is useful in a style of programming where you want to
132 explicitly specify all fields that should get considered for serialization or deserialization.
133 <P>
134
135 <P>
136 <DL>
137 <DT><B>Author:</B></DT>
138 <DD>Inderjeet Singh, Joel Leitch</DD>
139 </DL>
140 <HR>
141
142 <P>
143 <!-- =========== ANNOTATION TYPE OPTIONAL MEMBER SUMMARY =========== -->
144
145 <A NAME="annotation_type_optional_element_summary"><!-- --></A>
146 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
147 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
148 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
149 <B>Optional Element Summary</B></FONT></TH>
150 </TR>
151 <TR BGCOLOR="white" CLASS="TableRowColor">
152 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
153 <CODE>&nbsp;boolean</CODE></FONT></TD>
154 <TD><CODE><B><A HREF="../../../../com/google/gson/annotations/Expose.html#deserialize()">deserialize</A></B></CODE>
155
156 <BR>
157 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If <code>true</code>, the field marked with this annotation is deserialized from the JSON.</TD>
158 </TR>
159 <TR BGCOLOR="white" CLASS="TableRowColor">
160 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
161 <CODE>&nbsp;boolean</CODE></FONT></TD>
162 <TD><CODE><B><A HREF="../../../../com/google/gson/annotations/Expose.html#serialize()">serialize</A></B></CODE>
163
164 <BR>
165 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If <code>true</code>, the field marked with this annotation is written out in the JSON while
166 serializing.</TD>
167 </TR>
168 </TABLE>
169 &nbsp;
170 <P>
171 <A NAME="serialize()"><!-- --></A><H3>
172 serialize</H3>
173 <PRE>
174 public abstract boolean <B>serialize</B></PRE>
175 <DL>
176 <DD>If <code>true</code>, the field marked with this annotation is written out in the JSON while
177 serializing. If <code>false</code>, the field marked with this annotation is skipped from the
178 serialized output. Defaults to <code>true</code>.
179 <P>
180 <DD><DL>
181 </DL>
182 </DD>
183 <DD><DL>
184 <DT><B>Since:</B></DT>
185 <DD>1.4</DD>
186 </DL>
187 <DL>
188 <DT><B>Default:</B><DD>true</DD>
189 </DL>
190 </DL>
191 <HR>
192
193 <A NAME="deserialize()"><!-- --></A><H3>
194 deserialize</H3>
195 <PRE>
196 public abstract boolean <B>deserialize</B></PRE>
197 <DL>
198 <DD>If <code>true</code>, the field marked with this annotation is deserialized from the JSON.
199 If <code>false</code>, the field marked with this annotation is skipped during deserialization.
200 Defaults to <code>true</code>.
201 <P>
202 <DD><DL>
203 </DL>
204 </DD>
205 <DD><DL>
206 <DT><B>Since:</B></DT>
207 <DD>1.4</DD>
208 </DL>
209 <DL>
210 <DT><B>Default:</B><DD>true</DD>
211 </DL>
212 </DL>
213 <!-- ========= END OF CLASS DATA ========= -->
214 <HR>
215
216
217 <!-- ======= START OF BOTTOM NAVBAR ====== -->
218 <A NAME="navbar_bottom"><!-- --></A>
219 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
220 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
221 <TR>
222 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
223 <A NAME="navbar_bottom_firstrow"><!-- --></A>
224 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
225 <TR ALIGN="center" VALIGN="top">
226 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
227 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
228 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
229 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Expose.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
230 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
231 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
232 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
233 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
234 </TR>
235 </TABLE>
236 </TD>
237 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
238 </EM>
239 </TD>
240 </TR>
241
242 <TR>
243 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
244 &nbsp;PREV CLASS&nbsp;
245 &nbsp;<A HREF="../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
246 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
247 <A HREF="../../../../index.html?com/google/gson/annotations/Expose.html" target="_top"><B>FRAMES</B></A> &nbsp;
248 &nbsp;<A HREF="Expose.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
249 &nbsp;<SCRIPT type="text/javascript">
250 <!--
251 if(window==top) {
252 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
253 }
254 //-->
255 </SCRIPT>
256 <NOSCRIPT>
257 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
258 </NOSCRIPT>
259
260
261 </FONT></TD>
262 </TR>
263 <TR>
264 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
265 SUMMARY:&nbsp;REQUIRED&nbsp;|&nbsp;<A HREF="#annotation_type_optional_element_summary">OPTIONAL</A></FONT></TD>
266 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
267 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
268 </TR>
269 </TABLE>
270 <A NAME="skip-navbar_bottom"></A>
271 <!-- ======== END OF BOTTOM NAVBAR ======= -->
272
273 <HR>
274 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
275 </BODY>
276 </HTML>
+0
-275
gson/docs/javadocs/com/google/gson/annotations/JsonAdapter.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonAdapter (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonAdapter (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonAdapter.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/JsonAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.annotations</FONT>
92 <BR>
93 Annotation Type JsonAdapter</H2>
94 <HR>
95 <DL>
96 <DT><PRE><FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</A>)
97 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>={<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#TYPE" title="class or interface in java.lang.annotation">TYPE</A>,<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</A>})
98 </FONT>public @interface <B>JsonAdapter</B></DL>
99 </PRE>
100
101 <P>
102 An annotation that indicates the Gson <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A> to use with a class
103 or field.
104
105 <p>Here is an example of how this annotation is used:</p>
106 <pre>
107 &#64JsonAdapter(UserJsonAdapter.class)
108 public class User {
109 public final String firstName, lastName;
110 private User(String firstName, String lastName) {
111 this.firstName = firstName;
112 this.lastName = lastName;
113 }
114 }
115 public class UserJsonAdapter extends TypeAdapter&lt;User&gt; {
116 &#64Override public void write(JsonWriter out, User user) throws IOException {
117 // implement write: combine firstName and lastName into name
118 out.beginObject();
119 out.name("name");
120 out.value(user.firstName + " " + user.lastName);
121 out.endObject();
122 // implement the write method
123 }
124 &#64Override public User read(JsonReader in) throws IOException {
125 // implement read: split name into firstName and lastName
126 in.beginObject();
127 in.nextName();
128 String[] nameParts = in.nextString().split(" ");
129 in.endObject();
130 return new User(nameParts[0], nameParts[1]);
131 }
132 }
133 </pre>
134
135 Since User class specified UserJsonAdapter.class in &#64JsonAdapter annotation, it
136 will automatically be invoked to serialize/deserialize User instances. <br>
137
138 <p> Here is an example of how to apply this annotation to a field.
139 <pre>
140 private static final class Gadget {
141 &#64JsonAdapter(UserJsonAdapter2.class)
142 final User user;
143 Gadget(User user) {
144 this.user = user;
145 }
146 }
147 </pre>
148
149 It's possible to specify different type adapters on a field, that
150 field's type, and in the <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A>. Field
151 annotations take precedence over <code>GsonBuilder</code>-registered type
152 adapters, which in turn take precedence over annotated types.
153
154 <p>The class referenced by this annotation must be either a <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A> or a <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><CODE>TypeAdapterFactory</CODE></A>. Using the factory interface
155 makes it possible to delegate to the enclosing <code>Gson</code> instance.
156 <P>
157
158 <P>
159 <DL>
160 <DT><B>Since:</B></DT>
161 <DD>2.3</DD>
162 <DT><B>Author:</B></DT>
163 <DD>Inderjeet Singh, Joel Leitch, Jesse Wilson</DD>
164 </DL>
165 <HR>
166
167 <P>
168 <!-- =========== ANNOTATION TYPE REQUIRED MEMBER SUMMARY =========== -->
169
170 <A NAME="annotation_type_required_element_summary"><!-- --></A>
171 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
172 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
173 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
174 <B>Required Element Summary</B></FONT></TH>
175 </TR>
176 <TR BGCOLOR="white" CLASS="TableRowColor">
177 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
178 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;</CODE></FONT></TD>
179 <TD><CODE><B><A HREF="../../../../com/google/gson/annotations/JsonAdapter.html#value()">value</A></B></CODE>
180
181 <BR>
182 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Either a <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A> or <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><CODE>TypeAdapterFactory</CODE></A>.</TD>
183 </TR>
184 </TABLE>
185 &nbsp;
186 <P>
187
188 <!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== -->
189
190 <A NAME="annotation_type_element_detail"><!-- --></A>
191 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
192 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
193 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
194 <B>Element Detail</B></FONT></TH>
195 </TR>
196 </TABLE>
197
198 <A NAME="value()"><!-- --></A><H3>
199 value</H3>
200 <PRE>
201 public abstract <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt; <B>value</B></PRE>
202 <DL>
203 <DD>Either a <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A> or <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><CODE>TypeAdapterFactory</CODE></A>.
204 <P>
205 <DD><DL>
206 </DL>
207 </DD>
208 <DD><DL>
209 </DL>
210 </DL>
211 <!-- ========= END OF CLASS DATA ========= -->
212 <HR>
213
214
215 <!-- ======= START OF BOTTOM NAVBAR ====== -->
216 <A NAME="navbar_bottom"><!-- --></A>
217 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
218 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
219 <TR>
220 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
221 <A NAME="navbar_bottom_firstrow"><!-- --></A>
222 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
223 <TR ALIGN="center" VALIGN="top">
224 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
225 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
226 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
227 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonAdapter.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
228 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
229 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
230 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
231 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
232 </TR>
233 </TABLE>
234 </TD>
235 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
236 </EM>
237 </TD>
238 </TR>
239
240 <TR>
241 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
242 &nbsp;<A HREF="../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
243 &nbsp;<A HREF="../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
244 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
245 <A HREF="../../../../index.html?com/google/gson/annotations/JsonAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
246 &nbsp;<A HREF="JsonAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
247 &nbsp;<SCRIPT type="text/javascript">
248 <!--
249 if(window==top) {
250 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
251 }
252 //-->
253 </SCRIPT>
254 <NOSCRIPT>
255 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
256 </NOSCRIPT>
257
258
259 </FONT></TD>
260 </TR>
261 <TR>
262 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
263 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
264 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
265 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
266 </TR>
267 </TABLE>
268 <A NAME="skip-navbar_bottom"></A>
269 <!-- ======== END OF BOTTOM NAVBAR ======= -->
270
271 <HR>
272 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
273 </BODY>
274 </HTML>
+0
-253
gson/docs/javadocs/com/google/gson/annotations/SerializedName.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 SerializedName (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="SerializedName (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/SerializedName.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/SerializedName.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="SerializedName.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.annotations</FONT>
92 <BR>
93 Annotation Type SerializedName</H2>
94 <HR>
95 <DL>
96 <DT><PRE><FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</A>)
97 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</A>)
98 </FONT>public @interface <B>SerializedName</B></DL>
99 </PRE>
100
101 <P>
102 An annotation that indicates this member should be serialized to JSON with
103 the provided name value as its field name.
104
105 <p>This annotation will override any <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><CODE>FieldNamingPolicy</CODE></A>, including
106 the default field naming policy, that may have been set on the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A>
107 instance. A different naming policy can set using the <code>GsonBuilder</code> class. See
108 <A HREF="../../../../com/google/gson/GsonBuilder.html#setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)"><CODE>GsonBuilder.setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)</CODE></A>
109 for more information.</p>
110
111 <p>Here is an example of how this annotation is meant to be used:</p>
112 <pre>
113 public class SomeClassWithFields {
114 &#64SerializedName("name") private final String someField;
115 private final String someOtherField;
116
117 public SomeClassWithFields(String a, String b) {
118 this.someField = a;
119 this.someOtherField = b;
120 }
121 }
122 </pre>
123
124 <p>The following shows the output that is generated when serializing an instance of the
125 above example class:</p>
126 <pre>
127 SomeClassWithFields objectToSerialize = new SomeClassWithFields("a", "b");
128 Gson gson = new Gson();
129 String jsonRepresentation = gson.toJson(objectToSerialize);
130 System.out.println(jsonRepresentation);
131
132 ===== OUTPUT =====
133 {"name":"a","someOtherField":"b"}
134 </pre>
135
136 <p>NOTE: The value you specify in this annotation must be a valid JSON field name.</p>
137 <P>
138
139 <P>
140 <DL>
141 <DT><B>Author:</B></DT>
142 <DD>Inderjeet Singh, Joel Leitch</DD>
143 <DT><B>See Also:</B><DD><A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><CODE>FieldNamingPolicy</CODE></A></DL>
144 <HR>
145
146 <P>
147 <!-- =========== ANNOTATION TYPE REQUIRED MEMBER SUMMARY =========== -->
148
149 <A NAME="annotation_type_required_element_summary"><!-- --></A>
150 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
151 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
152 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
153 <B>Required Element Summary</B></FONT></TH>
154 </TR>
155 <TR BGCOLOR="white" CLASS="TableRowColor">
156 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
157 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
158 <TD><CODE><B><A HREF="../../../../com/google/gson/annotations/SerializedName.html#value()">value</A></B></CODE>
159
160 <BR>
161 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
162 </TR>
163 </TABLE>
164 &nbsp;
165 <P>
166
167 <!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== -->
168
169 <A NAME="annotation_type_element_detail"><!-- --></A>
170 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
171 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
172 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
173 <B>Element Detail</B></FONT></TH>
174 </TR>
175 </TABLE>
176
177 <A NAME="value()"><!-- --></A><H3>
178 value</H3>
179 <PRE>
180 public abstract <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>value</B></PRE>
181 <DL>
182 <DD><DL>
183 </DL>
184 </DD>
185 <DD><DL>
186
187 <DT><B>Returns:</B><DD>the desired name of the field when it is serialized</DL>
188 </DL>
189 <!-- ========= END OF CLASS DATA ========= -->
190 <HR>
191
192
193 <!-- ======= START OF BOTTOM NAVBAR ====== -->
194 <A NAME="navbar_bottom"><!-- --></A>
195 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
196 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
197 <TR>
198 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
199 <A NAME="navbar_bottom_firstrow"><!-- --></A>
200 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
201 <TR ALIGN="center" VALIGN="top">
202 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
203 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
204 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
205 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/SerializedName.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
206 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
207 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
208 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
209 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
210 </TR>
211 </TABLE>
212 </TD>
213 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
214 </EM>
215 </TD>
216 </TR>
217
218 <TR>
219 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
220 &nbsp;<A HREF="../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
221 &nbsp;<A HREF="../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
222 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
223 <A HREF="../../../../index.html?com/google/gson/annotations/SerializedName.html" target="_top"><B>FRAMES</B></A> &nbsp;
224 &nbsp;<A HREF="SerializedName.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
225 &nbsp;<SCRIPT type="text/javascript">
226 <!--
227 if(window==top) {
228 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
229 }
230 //-->
231 </SCRIPT>
232 <NOSCRIPT>
233 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
234 </NOSCRIPT>
235
236
237 </FONT></TD>
238 </TR>
239 <TR>
240 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
241 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
242 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
243 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
244 </TR>
245 </TABLE>
246 <A NAME="skip-navbar_bottom"></A>
247 <!-- ======== END OF BOTTOM NAVBAR ======= -->
248
249 <HR>
250 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
251 </BODY>
252 </HTML>
+0
-245
gson/docs/javadocs/com/google/gson/annotations/Since.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Since (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Since (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Since.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/Since.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Since.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.annotations</FONT>
92 <BR>
93 Annotation Type Since</H2>
94 <HR>
95 <DL>
96 <DT><PRE><FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</A>)
97 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>={<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</A>,<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#TYPE" title="class or interface in java.lang.annotation">TYPE</A>})
98 </FONT>public @interface <B>Since</B></DL>
99 </PRE>
100
101 <P>
102 An annotation that indicates the version number since a member or a type has been present.
103 This annotation is useful to manage versioning of your Json classes for a web-service.
104
105 <p>
106 This annotation has no effect unless you build <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> with a
107 <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A> and invoke
108 <A HREF="../../../../com/google/gson/GsonBuilder.html#setVersion(double)"><CODE>GsonBuilder.setVersion(double)</CODE></A> method.
109
110 <p>Here is an example of how this annotation is meant to be used:</p>
111 <pre>
112 public class User {
113 private String firstName;
114 private String lastName;
115 &#64Since(1.0) private String emailAddress;
116 &#64Since(1.0) private String password;
117 &#64Since(1.1) private Address address;
118 }
119 </pre>
120
121 <p>If you created Gson with <code>new Gson()</code>, the <code>toJson()</code> and <code>fromJson()</code>
122 methods will use all the fields for serialization and deserialization. However, if you created
123 Gson with <code>Gson gson = new GsonBuilder().setVersion(1.0).create()</code> then the
124 <code>toJson()</code> and <code>fromJson()</code> methods of Gson will exclude the <code>address</code> field
125 since it's version number is set to <code>1.1</code>.</p>
126 <P>
127
128 <P>
129 <DL>
130 <DT><B>Author:</B></DT>
131 <DD>Inderjeet Singh, Joel Leitch</DD>
132 </DL>
133 <HR>
134
135 <P>
136 <!-- =========== ANNOTATION TYPE REQUIRED MEMBER SUMMARY =========== -->
137
138 <A NAME="annotation_type_required_element_summary"><!-- --></A>
139 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
140 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
141 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
142 <B>Required Element Summary</B></FONT></TH>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
146 <CODE>&nbsp;double</CODE></FONT></TD>
147 <TD><CODE><B><A HREF="../../../../com/google/gson/annotations/Since.html#value()">value</A></B></CODE>
148
149 <BR>
150 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the value indicating a version number since this member
151 or type has been present.</TD>
152 </TR>
153 </TABLE>
154 &nbsp;
155 <P>
156
157 <!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== -->
158
159 <A NAME="annotation_type_element_detail"><!-- --></A>
160 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
161 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
162 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
163 <B>Element Detail</B></FONT></TH>
164 </TR>
165 </TABLE>
166
167 <A NAME="value()"><!-- --></A><H3>
168 value</H3>
169 <PRE>
170 public abstract double <B>value</B></PRE>
171 <DL>
172 <DD>the value indicating a version number since this member
173 or type has been present.
174 <P>
175 <DD><DL>
176 </DL>
177 </DD>
178 <DD><DL>
179 </DL>
180 </DL>
181 <!-- ========= END OF CLASS DATA ========= -->
182 <HR>
183
184
185 <!-- ======= START OF BOTTOM NAVBAR ====== -->
186 <A NAME="navbar_bottom"><!-- --></A>
187 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
188 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
189 <TR>
190 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
191 <A NAME="navbar_bottom_firstrow"><!-- --></A>
192 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
193 <TR ALIGN="center" VALIGN="top">
194 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
195 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
196 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
197 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Since.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
198 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
199 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
200 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
201 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
202 </TR>
203 </TABLE>
204 </TD>
205 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
206 </EM>
207 </TD>
208 </TR>
209
210 <TR>
211 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
212 &nbsp;<A HREF="../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
213 &nbsp;<A HREF="../../../../com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><B>NEXT CLASS</B></A></FONT></TD>
214 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
215 <A HREF="../../../../index.html?com/google/gson/annotations/Since.html" target="_top"><B>FRAMES</B></A> &nbsp;
216 &nbsp;<A HREF="Since.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
217 &nbsp;<SCRIPT type="text/javascript">
218 <!--
219 if(window==top) {
220 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
221 }
222 //-->
223 </SCRIPT>
224 <NOSCRIPT>
225 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
226 </NOSCRIPT>
227
228
229 </FONT></TD>
230 </TR>
231 <TR>
232 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
233 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
234 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
235 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
236 </TR>
237 </TABLE>
238 <A NAME="skip-navbar_bottom"></A>
239 <!-- ======== END OF BOTTOM NAVBAR ======= -->
240
241 <HR>
242 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
243 </BODY>
244 </HTML>
+0
-250
gson/docs/javadocs/com/google/gson/annotations/Until.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:54 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Until (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Until (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Until.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;NEXT CLASS</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/Until.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Until.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.annotations</FONT>
92 <BR>
93 Annotation Type Until</H2>
94 <HR>
95 <DL>
96 <DT><PRE><FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true" title="class or interface in java.lang.annotation">@Retention</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Retention.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>=<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/RetentionPolicy.html?is-external=true#RUNTIME" title="class or interface in java.lang.annotation">RUNTIME</A>)
97 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true" title="class or interface in java.lang.annotation">@Target</A>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Target.html?is-external=true#value()" title="class or interface in java.lang.annotation">value</A>={<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#FIELD" title="class or interface in java.lang.annotation">FIELD</A>,<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/ElementType.html?is-external=true#TYPE" title="class or interface in java.lang.annotation">TYPE</A>})
98 </FONT>public @interface <B>Until</B></DL>
99 </PRE>
100
101 <P>
102 An annotation that indicates the version number until a member or a type should be present.
103 Basically, if Gson is created with a version number that exceeds the value stored in the
104 <code>Until</code> annotation then the field will be ignored from the JSON output. This annotation
105 is useful to manage versioning of your JSON classes for a web-service.
106
107 <p>
108 This annotation has no effect unless you build <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> with a
109 <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A> and invoke
110 <A HREF="../../../../com/google/gson/GsonBuilder.html#setVersion(double)"><CODE>GsonBuilder.setVersion(double)</CODE></A> method.
111
112 <p>Here is an example of how this annotation is meant to be used:</p>
113 <pre>
114 public class User {
115 private String firstName;
116 private String lastName;
117 &#64Until(1.1) private String emailAddress;
118 &#64Until(1.1) private String password;
119 }
120 </pre>
121
122 <p>If you created Gson with <code>new Gson()</code>, the <code>toJson()</code> and <code>fromJson()</code>
123 methods will use all the fields for serialization and deserialization. However, if you created
124 Gson with <code>Gson gson = new GsonBuilder().setVersion(1.2).create()</code> then the
125 <code>toJson()</code> and <code>fromJson()</code> methods of Gson will exclude the <code>emailAddress</code>
126 and <code>password</code> fields from the example above, because the version number passed to the
127 GsonBuilder, <code>1.2</code>, exceeds the version number set on the <code>Until</code> annotation,
128 <code>1.1</code>, for those fields.
129 <P>
130
131 <P>
132 <DL>
133 <DT><B>Since:</B></DT>
134 <DD>1.3</DD>
135 <DT><B>Author:</B></DT>
136 <DD>Inderjeet Singh, Joel Leitch</DD>
137 </DL>
138 <HR>
139
140 <P>
141 <!-- =========== ANNOTATION TYPE REQUIRED MEMBER SUMMARY =========== -->
142
143 <A NAME="annotation_type_required_element_summary"><!-- --></A>
144 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
145 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
146 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
147 <B>Required Element Summary</B></FONT></TH>
148 </TR>
149 <TR BGCOLOR="white" CLASS="TableRowColor">
150 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
151 <CODE>&nbsp;double</CODE></FONT></TD>
152 <TD><CODE><B><A HREF="../../../../com/google/gson/annotations/Until.html#value()">value</A></B></CODE>
153
154 <BR>
155 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the value indicating a version number until this member
156 or type should be ignored.</TD>
157 </TR>
158 </TABLE>
159 &nbsp;
160 <P>
161
162 <!-- ============ ANNOTATION TYPE MEMBER DETAIL =========== -->
163
164 <A NAME="annotation_type_element_detail"><!-- --></A>
165 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
166 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
167 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
168 <B>Element Detail</B></FONT></TH>
169 </TR>
170 </TABLE>
171
172 <A NAME="value()"><!-- --></A><H3>
173 value</H3>
174 <PRE>
175 public abstract double <B>value</B></PRE>
176 <DL>
177 <DD>the value indicating a version number until this member
178 or type should be ignored.
179 <P>
180 <DD><DL>
181 </DL>
182 </DD>
183 <DD><DL>
184 </DL>
185 </DL>
186 <!-- ========= END OF CLASS DATA ========= -->
187 <HR>
188
189
190 <!-- ======= START OF BOTTOM NAVBAR ====== -->
191 <A NAME="navbar_bottom"><!-- --></A>
192 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
193 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
194 <TR>
195 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
196 <A NAME="navbar_bottom_firstrow"><!-- --></A>
197 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
198 <TR ALIGN="center" VALIGN="top">
199 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
200 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
201 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
202 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/Until.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
203 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
204 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
205 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
206 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
207 </TR>
208 </TABLE>
209 </TD>
210 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
211 </EM>
212 </TD>
213 </TR>
214
215 <TR>
216 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
217 &nbsp;<A HREF="../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>PREV CLASS</B></A>&nbsp;
218 &nbsp;NEXT CLASS</FONT></TD>
219 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
220 <A HREF="../../../../index.html?com/google/gson/annotations/Until.html" target="_top"><B>FRAMES</B></A> &nbsp;
221 &nbsp;<A HREF="Until.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
222 &nbsp;<SCRIPT type="text/javascript">
223 <!--
224 if(window==top) {
225 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
226 }
227 //-->
228 </SCRIPT>
229 <NOSCRIPT>
230 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
231 </NOSCRIPT>
232
233
234 </FONT></TD>
235 </TR>
236 <TR>
237 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
238 SUMMARY:&nbsp;<A HREF="#annotation_type_required_element_summary">REQUIRED</A>&nbsp;|&nbsp;OPTIONAL</FONT></TD>
239 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
240 DETAIL:&nbsp;<A HREF="#annotation_type_element_detail">ELEMENT</A></FONT></TD>
241 </TR>
242 </TABLE>
243 <A NAME="skip-navbar_bottom"></A>
244 <!-- ======== END OF BOTTOM NAVBAR ======= -->
245
246 <HR>
247 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
248 </BODY>
249 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/annotations/class-use/Expose.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.annotations.Expose (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.annotations.Expose (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useExpose.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Expose.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.annotations.Expose</B></H2>
85 </CENTER>
86 No usage of com.google.gson.annotations.Expose
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useExpose.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="Expose.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/annotations/class-use/JsonAdapter.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.annotations.JsonAdapter (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.annotations.JsonAdapter (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useJsonAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.annotations.JsonAdapter</B></H2>
85 </CENTER>
86 No usage of com.google.gson.annotations.JsonAdapter
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useJsonAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="JsonAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/annotations/class-use/SerializedName.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.annotations.SerializedName (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.annotations.SerializedName (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useSerializedName.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="SerializedName.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.annotations.SerializedName</B></H2>
85 </CENTER>
86 No usage of com.google.gson.annotations.SerializedName
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useSerializedName.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="SerializedName.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/annotations/class-use/Since.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.annotations.Since (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.annotations.Since (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useSince.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Since.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.annotations.Since</B></H2>
85 </CENTER>
86 No usage of com.google.gson.annotations.Since
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useSince.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="Since.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/annotations/class-use/Until.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.annotations.Until (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.annotations.Until (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useUntil.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Until.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.annotations.Until</B></H2>
85 </CENTER>
86 No usage of com.google.gson.annotations.Until
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../../index.html?com/google/gson/annotations//class-useUntil.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="Until.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-41
gson/docs/javadocs/com/google/gson/annotations/package-frame.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.annotations (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18 <FONT size="+1" CLASS="FrameTitleFont">
19 <A HREF="../../../../com/google/gson/annotations/package-summary.html" target="classFrame">com.google.gson.annotations</A></FONT>
20 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
21 <TR>
22 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
23 Annotation Types</FONT>&nbsp;
24 <FONT CLASS="FrameItemFont">
25 <BR>
26 <A HREF="Expose.html" title="annotation in com.google.gson.annotations" target="classFrame">Expose</A>
27 <BR>
28 <A HREF="JsonAdapter.html" title="annotation in com.google.gson.annotations" target="classFrame">JsonAdapter</A>
29 <BR>
30 <A HREF="SerializedName.html" title="annotation in com.google.gson.annotations" target="classFrame">SerializedName</A>
31 <BR>
32 <A HREF="Since.html" title="annotation in com.google.gson.annotations" target="classFrame">Since</A>
33 <BR>
34 <A HREF="Until.html" title="annotation in com.google.gson.annotations" target="classFrame">Until</A></FONT></TD>
35 </TR>
36 </TABLE>
37
38
39 </BODY>
40 </HTML>
+0
-194
gson/docs/javadocs/com/google/gson/annotations/package-summary.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.annotations (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson.annotations (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <H2>
83 Package com.google.gson.annotations
84 </H2>
85 This package provides annotations that can be used with <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A>.
86 <P>
87 <B>See:</B>
88 <BR>
89 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF="#package_description"><B>Description</B></A>
90 <P>
91
92 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
93 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
94 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
95 <B>Annotation Types Summary</B></FONT></TH>
96 </TR>
97 <TR BGCOLOR="white" CLASS="TableRowColor">
98 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations">Expose</A></B></TD>
99 <TD>An annotation that indicates this member should be exposed for JSON
100 serialization or deserialization.</TD>
101 </TR>
102 <TR BGCOLOR="white" CLASS="TableRowColor">
103 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations">JsonAdapter</A></B></TD>
104 <TD>An annotation that indicates the Gson <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A> to use with a class
105 or field.</TD>
106 </TR>
107 <TR BGCOLOR="white" CLASS="TableRowColor">
108 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations">SerializedName</A></B></TD>
109 <TD>An annotation that indicates this member should be serialized to JSON with
110 the provided name value as its field name.</TD>
111 </TR>
112 <TR BGCOLOR="white" CLASS="TableRowColor">
113 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations">Since</A></B></TD>
114 <TD>An annotation that indicates the version number since a member or a type has been present.</TD>
115 </TR>
116 <TR BGCOLOR="white" CLASS="TableRowColor">
117 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations">Until</A></B></TD>
118 <TD>An annotation that indicates the version number until a member or a type should be present.</TD>
119 </TR>
120 </TABLE>
121 &nbsp;
122
123 <P>
124 <A NAME="package_description"><!-- --></A><H2>
125 Package com.google.gson.annotations Description
126 </H2>
127
128 <P>
129 This package provides annotations that can be used with <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A>.
130 <P>
131
132 <P>
133 <DL>
134 <DT><B>Author:</B></DT>
135 <DD>Inderjeet Singh, Joel Leitch</DD>
136 </DL>
137 <HR>
138
139
140 <!-- ======= START OF BOTTOM NAVBAR ====== -->
141 <A NAME="navbar_bottom"><!-- --></A>
142 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
143 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
144 <TR>
145 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
146 <A NAME="navbar_bottom_firstrow"><!-- --></A>
147 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
148 <TR ALIGN="center" VALIGN="top">
149 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
150 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
155 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
156 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
157 </TR>
158 </TABLE>
159 </TD>
160 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
161 </EM>
162 </TD>
163 </TR>
164
165 <TR>
166 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
167 &nbsp;<A HREF="../../../../com/google/gson/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
168 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
169 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
170 <A HREF="../../../../index.html?com/google/gson/annotations/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
171 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
172 &nbsp;<SCRIPT type="text/javascript">
173 <!--
174 if(window==top) {
175 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
176 }
177 //-->
178 </SCRIPT>
179 <NOSCRIPT>
180 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
181 </NOSCRIPT>
182
183
184 </FONT></TD>
185 </TR>
186 </TABLE>
187 <A NAME="skip-navbar_bottom"></A>
188 <!-- ======== END OF BOTTOM NAVBAR ======= -->
189
190 <HR>
191 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
192 </BODY>
193 </HTML>
+0
-157
gson/docs/javadocs/com/google/gson/annotations/package-tree.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.annotations Class Hierarchy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson.annotations Class Hierarchy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/package-tree.html"><B>PREV</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-tree.html"><B>NEXT</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 Hierarchy For Package com.google.gson.annotations
85 </H2>
86 </CENTER>
87 <DL>
88 <DT><B>Package Hierarchies:</B><DD><A HREF="../../../../overview-tree.html">All Packages</A></DL>
89 <HR>
90 <H2>
91 Annotation Type Hierarchy
92 </H2>
93 <UL>
94 <LI TYPE="circle">com.google.gson.annotations.<A HREF="../../../../com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><B>Until</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
95 <LI TYPE="circle">com.google.gson.annotations.<A HREF="../../../../com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>Since</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
96 <LI TYPE="circle">com.google.gson.annotations.<A HREF="../../../../com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>SerializedName</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
97 <LI TYPE="circle">com.google.gson.annotations.<A HREF="../../../../com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>JsonAdapter</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
98 <LI TYPE="circle">com.google.gson.annotations.<A HREF="../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><B>Expose</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
99 </UL>
100 <HR>
101
102
103 <!-- ======= START OF BOTTOM NAVBAR ====== -->
104 <A NAME="navbar_bottom"><!-- --></A>
105 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
106 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
107 <TR>
108 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
109 <A NAME="navbar_bottom_firstrow"><!-- --></A>
110 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
111 <TR ALIGN="center" VALIGN="top">
112 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
113 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
114 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
115 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
116 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
117 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
118 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
119 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
120 </TR>
121 </TABLE>
122 </TD>
123 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
124 </EM>
125 </TD>
126 </TR>
127
128 <TR>
129 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
130 &nbsp;<A HREF="../../../../com/google/gson/package-tree.html"><B>PREV</B></A>&nbsp;
131 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-tree.html"><B>NEXT</B></A></FONT></TD>
132 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
133 <A HREF="../../../../index.html?com/google/gson/annotations/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
134 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
135 &nbsp;<SCRIPT type="text/javascript">
136 <!--
137 if(window==top) {
138 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
139 }
140 //-->
141 </SCRIPT>
142 <NOSCRIPT>
143 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
144 </NOSCRIPT>
145
146
147 </FONT></TD>
148 </TR>
149 </TABLE>
150 <A NAME="skip-navbar_bottom"></A>
151 <!-- ======== END OF BOTTOM NAVBAR ======= -->
152
153 <HR>
154 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
155 </BODY>
156 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/annotations/package-use.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Package com.google.gson.annotations (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Package com.google.gson.annotations (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/annotations/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Package<br>com.google.gson.annotations</B></H2>
85 </CENTER>
86 No usage of com.google.gson.annotations
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../index.html?com/google/gson/annotations/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-199
gson/docs/javadocs/com/google/gson/class-use/ExclusionStrategy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.ExclusionStrategy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.ExclusionStrategy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useExclusionStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="ExclusionStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.ExclusionStrategy</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
117 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)">addDeserializationExclusionStrategy</A></B>(<A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply the passed in exclusion strategy during deserialization.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
125 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#addSerializationExclusionStrategy(com.google.gson.ExclusionStrategy)">addSerializationExclusionStrategy</A></B>(<A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply the passed in exclusion strategy during serialization.</TD>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
133 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setExclusionStrategies(com.google.gson.ExclusionStrategy...)">setExclusionStrategies</A></B>(<A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>...&nbsp;strategies)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a set of exclusion strategies during both serialization and
137 deserialization.</TD>
138 </TR>
139 </TABLE>
140 &nbsp;
141 <P>
142 <HR>
143
144
145 <!-- ======= START OF BOTTOM NAVBAR ====== -->
146 <A NAME="navbar_bottom"><!-- --></A>
147 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
148 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
149 <TR>
150 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
151 <A NAME="navbar_bottom_firstrow"><!-- --></A>
152 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
153 <TR ALIGN="center" VALIGN="top">
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
155 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
156 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
157 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
158 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
159 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
160 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
161 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
162 </TR>
163 </TABLE>
164 </TD>
165 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
166 </EM>
167 </TD>
168 </TR>
169
170 <TR>
171 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
172 &nbsp;PREV&nbsp;
173 &nbsp;NEXT</FONT></TD>
174 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
175 <A HREF="../../../../index.html?com/google/gson//class-useExclusionStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
176 &nbsp;<A HREF="ExclusionStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
177 &nbsp;<SCRIPT type="text/javascript">
178 <!--
179 if(window==top) {
180 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
181 }
182 //-->
183 </SCRIPT>
184 <NOSCRIPT>
185 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
186 </NOSCRIPT>
187
188
189 </FONT></TD>
190 </TR>
191 </TABLE>
192 <A NAME="skip-navbar_bottom"></A>
193 <!-- ======== END OF BOTTOM NAVBAR ======= -->
194
195 <HR>
196 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
197 </BODY>
198 </HTML>
+0
-182
gson/docs/javadocs/com/google/gson/class-use/FieldAttributes.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.FieldAttributes (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.FieldAttributes (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useFieldAttributes.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="FieldAttributes.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.FieldAttributes</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;boolean</CODE></FONT></TD>
117 <TD><CODE><B>ExclusionStrategy.</B><B><A HREF="../../../../com/google/gson/ExclusionStrategy.html#shouldSkipField(com.google.gson.FieldAttributes)">shouldSkipField</A></B>(<A HREF="../../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>&nbsp;f)</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
121 </TR>
122 </TABLE>
123 &nbsp;
124 <P>
125 <HR>
126
127
128 <!-- ======= START OF BOTTOM NAVBAR ====== -->
129 <A NAME="navbar_bottom"><!-- --></A>
130 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
131 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
132 <TR>
133 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
134 <A NAME="navbar_bottom_firstrow"><!-- --></A>
135 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
136 <TR ALIGN="center" VALIGN="top">
137 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
138 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
139 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
140 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
141 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
142 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
143 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
144 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
145 </TR>
146 </TABLE>
147 </TD>
148 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
149 </EM>
150 </TD>
151 </TR>
152
153 <TR>
154 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
155 &nbsp;PREV&nbsp;
156 &nbsp;NEXT</FONT></TD>
157 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
158 <A HREF="../../../../index.html?com/google/gson//class-useFieldAttributes.html" target="_top"><B>FRAMES</B></A> &nbsp;
159 &nbsp;<A HREF="FieldAttributes.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
160 &nbsp;<SCRIPT type="text/javascript">
161 <!--
162 if(window==top) {
163 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
164 }
165 //-->
166 </SCRIPT>
167 <NOSCRIPT>
168 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
169 </NOSCRIPT>
170
171
172 </FONT></TD>
173 </TR>
174 </TABLE>
175 <A NAME="skip-navbar_bottom"></A>
176 <!-- ======== END OF BOTTOM NAVBAR ======= -->
177
178 <HR>
179 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
180 </BODY>
181 </HTML>
+0
-208
gson/docs/javadocs/com/google/gson/class-use/FieldNamingPolicy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.FieldNamingPolicy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.FieldNamingPolicy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useFieldNamingPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="FieldNamingPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.FieldNamingPolicy</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></CODE></FONT></TD>
117 <TD><CODE><B>FieldNamingPolicy.</B><B><A HREF="../../../../com/google/gson/FieldNamingPolicy.html#valueOf(java.lang.String)">valueOf</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the enum constant of this type with the specified name.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>[]</CODE></FONT></TD>
125 <TD><CODE><B>FieldNamingPolicy.</B><B><A HREF="../../../../com/google/gson/FieldNamingPolicy.html#values()">values</A></B>()</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an array containing the constants of this enum type, in
129 the order they are declared.</TD>
130 </TR>
131 </TABLE>
132 &nbsp;
133 <P>
134
135 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
136 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
137 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></FONT></TH>
138 </TR>
139 <TR BGCOLOR="white" CLASS="TableRowColor">
140 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
141 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
142 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)">setFieldNamingPolicy</A></B>(<A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&nbsp;namingConvention)</CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific naming policy to an object's field during serialization
146 and deserialization.</TD>
147 </TR>
148 </TABLE>
149 &nbsp;
150 <P>
151 <HR>
152
153
154 <!-- ======= START OF BOTTOM NAVBAR ====== -->
155 <A NAME="navbar_bottom"><!-- --></A>
156 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
157 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
158 <TR>
159 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
160 <A NAME="navbar_bottom_firstrow"><!-- --></A>
161 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
162 <TR ALIGN="center" VALIGN="top">
163 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
164 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
165 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
166 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
167 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
168 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
169 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
170 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
171 </TR>
172 </TABLE>
173 </TD>
174 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
175 </EM>
176 </TD>
177 </TR>
178
179 <TR>
180 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
181 &nbsp;PREV&nbsp;
182 &nbsp;NEXT</FONT></TD>
183 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
184 <A HREF="../../../../index.html?com/google/gson//class-useFieldNamingPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
185 &nbsp;<A HREF="FieldNamingPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
186 &nbsp;<SCRIPT type="text/javascript">
187 <!--
188 if(window==top) {
189 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
190 }
191 //-->
192 </SCRIPT>
193 <NOSCRIPT>
194 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
195 </NOSCRIPT>
196
197
198 </FONT></TD>
199 </TR>
200 </TABLE>
201 <A NAME="skip-navbar_bottom"></A>
202 <!-- ======== END OF BOTTOM NAVBAR ======= -->
203
204 <HR>
205 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
206 </BODY>
207 </HTML>
+0
-199
gson/docs/javadocs/com/google/gson/class-use/FieldNamingStrategy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.FieldNamingStrategy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.FieldNamingStrategy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useFieldNamingStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="FieldNamingStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.FieldNamingStrategy</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Classes in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that implement <A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;class</CODE></FONT></TD>
117 <TD><CODE><B><A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></B></CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An enumeration that defines a few standard naming conventions for JSON field names.</TD>
121 </TR>
122 </TABLE>
123 &nbsp;
124 <P>
125
126 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
127 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
128 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A></FONT></TH>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
133 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setFieldNamingStrategy(com.google.gson.FieldNamingStrategy)">setFieldNamingStrategy</A></B>(<A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>&nbsp;fieldNamingStrategy)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific naming policy strategy to an object's field during
137 serialization and deserialization.</TD>
138 </TR>
139 </TABLE>
140 &nbsp;
141 <P>
142 <HR>
143
144
145 <!-- ======= START OF BOTTOM NAVBAR ====== -->
146 <A NAME="navbar_bottom"><!-- --></A>
147 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
148 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
149 <TR>
150 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
151 <A NAME="navbar_bottom_firstrow"><!-- --></A>
152 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
153 <TR ALIGN="center" VALIGN="top">
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
155 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
156 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
157 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
158 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
159 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
160 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
161 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
162 </TR>
163 </TABLE>
164 </TD>
165 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
166 </EM>
167 </TD>
168 </TR>
169
170 <TR>
171 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
172 &nbsp;PREV&nbsp;
173 &nbsp;NEXT</FONT></TD>
174 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
175 <A HREF="../../../../index.html?com/google/gson//class-useFieldNamingStrategy.html" target="_top"><B>FRAMES</B></A> &nbsp;
176 &nbsp;<A HREF="FieldNamingStrategy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
177 &nbsp;<SCRIPT type="text/javascript">
178 <!--
179 if(window==top) {
180 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
181 }
182 //-->
183 </SCRIPT>
184 <NOSCRIPT>
185 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
186 </NOSCRIPT>
187
188
189 </FONT></TD>
190 </TR>
191 </TABLE>
192 <A NAME="skip-navbar_bottom"></A>
193 <!-- ======== END OF BOTTOM NAVBAR ======= -->
194
195 <HR>
196 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
197 </BODY>
198 </HTML>
+0
-207
gson/docs/javadocs/com/google/gson/class-use/Gson.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.Gson (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.Gson (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useGson.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="Gson.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.Gson</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A></CODE></FONT></TD>
117 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#create()">create</A></B>()</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance based on the current configuration.</TD>
121 </TR>
122 </TABLE>
123 &nbsp;
124 <P>
125
126 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
127 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
128 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A></FONT></TH>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>
133 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
134 <TR ALIGN="right" VALIGN="">
135 <TD NOWRAP><FONT SIZE="-1">
136 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
137 </TR>
138 </TABLE>
139 </CODE></FONT></TD>
140 <TD><CODE><B>TypeAdapterFactory.</B><B><A HREF="../../../../com/google/gson/TypeAdapterFactory.html#create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)">create</A></B>(<A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>&nbsp;gson,
141 <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
142
143 <BR>
144 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a type adapter for <code>type</code>, or null if this factory doesn't
145 support <code>type</code>.</TD>
146 </TR>
147 </TABLE>
148 &nbsp;
149 <P>
150 <HR>
151
152
153 <!-- ======= START OF BOTTOM NAVBAR ====== -->
154 <A NAME="navbar_bottom"><!-- --></A>
155 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
156 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
157 <TR>
158 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
159 <A NAME="navbar_bottom_firstrow"><!-- --></A>
160 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
161 <TR ALIGN="center" VALIGN="top">
162 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
163 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
164 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
165 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
166 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
167 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
168 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
169 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
170 </TR>
171 </TABLE>
172 </TD>
173 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
174 </EM>
175 </TD>
176 </TR>
177
178 <TR>
179 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
180 &nbsp;PREV&nbsp;
181 &nbsp;NEXT</FONT></TD>
182 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
183 <A HREF="../../../../index.html?com/google/gson//class-useGson.html" target="_top"><B>FRAMES</B></A> &nbsp;
184 &nbsp;<A HREF="Gson.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
185 &nbsp;<SCRIPT type="text/javascript">
186 <!--
187 if(window==top) {
188 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
189 }
190 //-->
191 </SCRIPT>
192 <NOSCRIPT>
193 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
194 </NOSCRIPT>
195
196
197 </FONT></TD>
198 </TR>
199 </TABLE>
200 <A NAME="skip-navbar_bottom"></A>
201 <!-- ======== END OF BOTTOM NAVBAR ======= -->
202
203 <HR>
204 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
205 </BODY>
206 </HTML>
+0
-361
gson/docs/javadocs/com/google/gson/class-use/GsonBuilder.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.GsonBuilder (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.GsonBuilder (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useGsonBuilder.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="GsonBuilder.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.GsonBuilder</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
117 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)">addDeserializationExclusionStrategy</A></B>(<A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply the passed in exclusion strategy during deserialization.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
125 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#addSerializationExclusionStrategy(com.google.gson.ExclusionStrategy)">addSerializationExclusionStrategy</A></B>(<A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>&nbsp;strategy)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply the passed in exclusion strategy during serialization.</TD>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
133 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#disableHtmlEscaping()">disableHtmlEscaping</A></B>()</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;By default, Gson escapes HTML characters such as &lt; &gt; etc.</TD>
137 </TR>
138 <TR BGCOLOR="white" CLASS="TableRowColor">
139 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
140 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
141 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#disableInnerClassSerialization()">disableInnerClassSerialization</A></B>()</CODE>
142
143 <BR>
144 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to exclude inner classes during serialization.</TD>
145 </TR>
146 <TR BGCOLOR="white" CLASS="TableRowColor">
147 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
148 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
149 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#enableComplexMapKeySerialization()">enableComplexMapKeySerialization</A></B>()</CODE>
150
151 <BR>
152 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Enabling this feature will only change the serialized form if the map key is
153 a complex type (i.e.</TD>
154 </TR>
155 <TR BGCOLOR="white" CLASS="TableRowColor">
156 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
157 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
158 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#excludeFieldsWithModifiers(int...)">excludeFieldsWithModifiers</A></B>(int...&nbsp;modifiers)</CODE>
159
160 <BR>
161 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to excludes all class fields that have the specified modifiers.</TD>
162 </TR>
163 <TR BGCOLOR="white" CLASS="TableRowColor">
164 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
165 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
166 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#excludeFieldsWithoutExposeAnnotation()">excludeFieldsWithoutExposeAnnotation</A></B>()</CODE>
167
168 <BR>
169 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to exclude all fields from consideration for serialization or deserialization
170 that do not have the <A HREF="../../../../com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><CODE>Expose</CODE></A> annotation.</TD>
171 </TR>
172 <TR BGCOLOR="white" CLASS="TableRowColor">
173 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
174 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
175 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#generateNonExecutableJson()">generateNonExecutableJson</A></B>()</CODE>
176
177 <BR>
178 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Makes the output JSON non-executable in Javascript by prefixing the generated JSON with some
179 special text.</TD>
180 </TR>
181 <TR BGCOLOR="white" CLASS="TableRowColor">
182 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
183 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
184 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)">registerTypeAdapter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type,
185 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;typeAdapter)</CODE>
186
187 <BR>
188 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson for custom serialization or deserialization.</TD>
189 </TR>
190 <TR BGCOLOR="white" CLASS="TableRowColor">
191 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
192 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
193 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#registerTypeAdapterFactory(com.google.gson.TypeAdapterFactory)">registerTypeAdapterFactory</A></B>(<A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;factory)</CODE>
194
195 <BR>
196 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Register a factory for type adapters.</TD>
197 </TR>
198 <TR BGCOLOR="white" CLASS="TableRowColor">
199 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
200 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
201 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#registerTypeHierarchyAdapter(java.lang.Class, java.lang.Object)">registerTypeHierarchyAdapter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;baseType,
202 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;typeAdapter)</CODE>
203
204 <BR>
205 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson for custom serialization or deserialization for an inheritance type hierarchy.</TD>
206 </TR>
207 <TR BGCOLOR="white" CLASS="TableRowColor">
208 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
209 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
210 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#serializeNulls()">serializeNulls</A></B>()</CODE>
211
212 <BR>
213 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configure Gson to serialize null fields.</TD>
214 </TR>
215 <TR BGCOLOR="white" CLASS="TableRowColor">
216 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
217 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
218 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#serializeSpecialFloatingPointValues()">serializeSpecialFloatingPointValues</A></B>()</CODE>
219
220 <BR>
221 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Section 2.4 of <a href="http://www.ietf.org/rfc/rfc4627.txt">JSON specification</a> disallows
222 special double values (NaN, Infinity, -Infinity).</TD>
223 </TR>
224 <TR BGCOLOR="white" CLASS="TableRowColor">
225 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
226 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
227 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setDateFormat(int)">setDateFormat</A></B>(int&nbsp;style)</CODE>
228
229 <BR>
230 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to to serialize <code>Date</code> objects according to the style value provided.</TD>
231 </TR>
232 <TR BGCOLOR="white" CLASS="TableRowColor">
233 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
234 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
235 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setDateFormat(int, int)">setDateFormat</A></B>(int&nbsp;dateStyle,
236 int&nbsp;timeStyle)</CODE>
237
238 <BR>
239 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to to serialize <code>Date</code> objects according to the style value provided.</TD>
240 </TR>
241 <TR BGCOLOR="white" CLASS="TableRowColor">
242 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
243 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
244 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setDateFormat(java.lang.String)">setDateFormat</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;pattern)</CODE>
245
246 <BR>
247 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to serialize <code>Date</code> objects according to the pattern provided.</TD>
248 </TR>
249 <TR BGCOLOR="white" CLASS="TableRowColor">
250 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
251 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
252 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setExclusionStrategies(com.google.gson.ExclusionStrategy...)">setExclusionStrategies</A></B>(<A HREF="../../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>...&nbsp;strategies)</CODE>
253
254 <BR>
255 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a set of exclusion strategies during both serialization and
256 deserialization.</TD>
257 </TR>
258 <TR BGCOLOR="white" CLASS="TableRowColor">
259 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
260 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
261 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)">setFieldNamingPolicy</A></B>(<A HREF="../../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>&nbsp;namingConvention)</CODE>
262
263 <BR>
264 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific naming policy to an object's field during serialization
265 and deserialization.</TD>
266 </TR>
267 <TR BGCOLOR="white" CLASS="TableRowColor">
268 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
269 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
270 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setFieldNamingStrategy(com.google.gson.FieldNamingStrategy)">setFieldNamingStrategy</A></B>(<A HREF="../../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>&nbsp;fieldNamingStrategy)</CODE>
271
272 <BR>
273 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific naming policy strategy to an object's field during
274 serialization and deserialization.</TD>
275 </TR>
276 <TR BGCOLOR="white" CLASS="TableRowColor">
277 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
278 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
279 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setLongSerializationPolicy(com.google.gson.LongSerializationPolicy)">setLongSerializationPolicy</A></B>(<A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&nbsp;serializationPolicy)</CODE>
280
281 <BR>
282 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific serialization policy for <code>Long</code> and <code>long</code>
283 objects.</TD>
284 </TR>
285 <TR BGCOLOR="white" CLASS="TableRowColor">
286 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
287 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
288 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setPrettyPrinting()">setPrettyPrinting</A></B>()</CODE>
289
290 <BR>
291 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to output Json that fits in a page for pretty printing.</TD>
292 </TR>
293 <TR BGCOLOR="white" CLASS="TableRowColor">
294 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
295 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
296 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setVersion(double)">setVersion</A></B>(double&nbsp;ignoreVersionsAfter)</CODE>
297
298 <BR>
299 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to enable versioning support.</TD>
300 </TR>
301 </TABLE>
302 &nbsp;
303 <P>
304 <HR>
305
306
307 <!-- ======= START OF BOTTOM NAVBAR ====== -->
308 <A NAME="navbar_bottom"><!-- --></A>
309 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
310 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
311 <TR>
312 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
313 <A NAME="navbar_bottom_firstrow"><!-- --></A>
314 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
315 <TR ALIGN="center" VALIGN="top">
316 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
317 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
318 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
319 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
320 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
321 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
322 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
323 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
324 </TR>
325 </TABLE>
326 </TD>
327 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
328 </EM>
329 </TD>
330 </TR>
331
332 <TR>
333 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
334 &nbsp;PREV&nbsp;
335 &nbsp;NEXT</FONT></TD>
336 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
337 <A HREF="../../../../index.html?com/google/gson//class-useGsonBuilder.html" target="_top"><B>FRAMES</B></A> &nbsp;
338 &nbsp;<A HREF="GsonBuilder.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
339 &nbsp;<SCRIPT type="text/javascript">
340 <!--
341 if(window==top) {
342 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
343 }
344 //-->
345 </SCRIPT>
346 <NOSCRIPT>
347 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
348 </NOSCRIPT>
349
350
351 </FONT></TD>
352 </TR>
353 </TABLE>
354 <A NAME="skip-navbar_bottom"></A>
355 <!-- ======== END OF BOTTOM NAVBAR ======= -->
356
357 <HR>
358 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
359 </BODY>
360 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/class-use/InstanceCreator.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.InstanceCreator (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.InstanceCreator (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useInstanceCreator.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="InstanceCreator.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.InstanceCreator</B></H2>
85 </CENTER>
86 No usage of com.google.gson.InstanceCreator
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../index.html?com/google/gson//class-useInstanceCreator.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="InstanceCreator.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-206
gson/docs/javadocs/com/google/gson/class-use/JsonArray.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonArray (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonArray (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonArray.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonArray.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonArray</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></CODE></FONT></TD>
117 <TD><CODE><B>JsonElement.</B><B><A HREF="../../../../com/google/gson/JsonElement.html#getAsJsonArray()">getAsJsonArray</A></B>()</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></CODE></FONT></TD>
125 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#getAsJsonArray(java.lang.String)">getAsJsonArray</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to get the specified member as a JsonArray.</TD>
129 </TR>
130 </TABLE>
131 &nbsp;
132 <P>
133
134 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
135 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
136 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></FONT></TH>
137 </TR>
138 <TR BGCOLOR="white" CLASS="TableRowColor">
139 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
140 <CODE>&nbsp;void</CODE></FONT></TD>
141 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#addAll(com.google.gson.JsonArray)">addAll</A></B>(<A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>&nbsp;array)</CODE>
142
143 <BR>
144 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds all the elements of the specified array to self.</TD>
145 </TR>
146 </TABLE>
147 &nbsp;
148 <P>
149 <HR>
150
151
152 <!-- ======= START OF BOTTOM NAVBAR ====== -->
153 <A NAME="navbar_bottom"><!-- --></A>
154 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
155 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
156 <TR>
157 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
158 <A NAME="navbar_bottom_firstrow"><!-- --></A>
159 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
160 <TR ALIGN="center" VALIGN="top">
161 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
162 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
163 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
164 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
165 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
166 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
167 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
168 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
169 </TR>
170 </TABLE>
171 </TD>
172 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
173 </EM>
174 </TD>
175 </TR>
176
177 <TR>
178 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
179 &nbsp;PREV&nbsp;
180 &nbsp;NEXT</FONT></TD>
181 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
182 <A HREF="../../../../index.html?com/google/gson//class-useJsonArray.html" target="_top"><B>FRAMES</B></A> &nbsp;
183 &nbsp;<A HREF="JsonArray.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
184 &nbsp;<SCRIPT type="text/javascript">
185 <!--
186 if(window==top) {
187 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
188 }
189 //-->
190 </SCRIPT>
191 <NOSCRIPT>
192 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
193 </NOSCRIPT>
194
195
196 </FONT></TD>
197 </TR>
198 </TABLE>
199 <A NAME="skip-navbar_bottom"></A>
200 <!-- ======== END OF BOTTOM NAVBAR ======= -->
201
202 <HR>
203 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
204 </BODY>
205 </HTML>
+0
-185
gson/docs/javadocs/com/google/gson/class-use/JsonDeserializationContext.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.JsonDeserializationContext (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.JsonDeserializationContext (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonDeserializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonDeserializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.JsonDeserializationContext</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonDeserializer.html" title="type parameter in JsonDeserializer">T</A></CODE></FONT></TD>
117 <TD><CODE><B>JsonDeserializer.</B><B><A HREF="../../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)">deserialize</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
118 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT,
119 <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A>&nbsp;context)</CODE>
120
121 <BR>
122 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during deserialization when it encounters a field of the
123 specified type.</TD>
124 </TR>
125 </TABLE>
126 &nbsp;
127 <P>
128 <HR>
129
130
131 <!-- ======= START OF BOTTOM NAVBAR ====== -->
132 <A NAME="navbar_bottom"><!-- --></A>
133 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
134 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
135 <TR>
136 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
137 <A NAME="navbar_bottom_firstrow"><!-- --></A>
138 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
139 <TR ALIGN="center" VALIGN="top">
140 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
141 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
142 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
143 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
144 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
145 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
146 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
148 </TR>
149 </TABLE>
150 </TD>
151 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
152 </EM>
153 </TD>
154 </TR>
155
156 <TR>
157 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
158 &nbsp;PREV&nbsp;
159 &nbsp;NEXT</FONT></TD>
160 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
161 <A HREF="../../../../index.html?com/google/gson//class-useJsonDeserializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
162 &nbsp;<A HREF="JsonDeserializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
163 &nbsp;<SCRIPT type="text/javascript">
164 <!--
165 if(window==top) {
166 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
167 }
168 //-->
169 </SCRIPT>
170 <NOSCRIPT>
171 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
172 </NOSCRIPT>
173
174
175 </FONT></TD>
176 </TR>
177 </TABLE>
178 <A NAME="skip-navbar_bottom"></A>
179 <!-- ======== END OF BOTTOM NAVBAR ======= -->
180
181 <HR>
182 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
183 </BODY>
184 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/class-use/JsonDeserializer.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.JsonDeserializer (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.JsonDeserializer (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonDeserializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonDeserializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.JsonDeserializer</B></H2>
85 </CENTER>
86 No usage of com.google.gson.JsonDeserializer
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../index.html?com/google/gson//class-useJsonDeserializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="JsonDeserializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-519
gson/docs/javadocs/com/google/gson/class-use/JsonElement.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonElement (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonElement (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonElement.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonElement.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonElement</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Subclasses of <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;class</CODE></FONT></TD>
117 <TD><CODE><B><A HREF="../../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></B></CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing an array type in Json.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>&nbsp;class</CODE></FONT></TD>
125 <TD><CODE><B><A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></B></CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing a Json <code>null</code> value.</TD>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>&nbsp;class</CODE></FONT></TD>
133 <TD><CODE><B><A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></B></CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing an object type in Json.</TD>
137 </TR>
138 <TR BGCOLOR="white" CLASS="TableRowColor">
139 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
140 <CODE>&nbsp;class</CODE></FONT></TD>
141 <TD><CODE><B><A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></B></CODE>
142
143 <BR>
144 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing a Json primitive value.</TD>
145 </TR>
146 </TABLE>
147 &nbsp;
148 <P>
149
150 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
151 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
152 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></FONT></TH>
153 </TR>
154 <TR BGCOLOR="white" CLASS="TableRowColor">
155 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
156 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
157 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#get(int)">get</A></B>(int&nbsp;i)</CODE>
158
159 <BR>
160 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the ith element of the array.</TD>
161 </TR>
162 <TR BGCOLOR="white" CLASS="TableRowColor">
163 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
164 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
165 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#get(java.lang.String)">get</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
166
167 <BR>
168 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the member with the specified name.</TD>
169 </TR>
170 <TR BGCOLOR="white" CLASS="TableRowColor">
171 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
172 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
173 <TD><CODE><B>JsonStreamParser.</B><B><A HREF="../../../../com/google/gson/JsonStreamParser.html#next()">next</A></B>()</CODE>
174
175 <BR>
176 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next available <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> on the reader.</TD>
177 </TR>
178 <TR BGCOLOR="white" CLASS="TableRowColor">
179 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
180 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
181 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(com.google.gson.stream.JsonReader)">parse</A></B>(<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;json)</CODE>
182
183 <BR>
184 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next value from the JSON stream as a parse tree.</TD>
185 </TR>
186 <TR BGCOLOR="white" CLASS="TableRowColor">
187 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
188 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
189 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(java.io.Reader)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json)</CODE>
190
191 <BR>
192 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
193 </TR>
194 <TR BGCOLOR="white" CLASS="TableRowColor">
195 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
196 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
197 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(java.lang.String)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)</CODE>
198
199 <BR>
200 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
201 </TR>
202 <TR BGCOLOR="white" CLASS="TableRowColor">
203 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
204 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
205 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#remove(int)">remove</A></B>(int&nbsp;index)</CODE>
206
207 <BR>
208 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the element at the specified position in this array.</TD>
209 </TR>
210 <TR BGCOLOR="white" CLASS="TableRowColor">
211 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
212 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
213 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#remove(java.lang.String)">remove</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property)</CODE>
214
215 <BR>
216 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the <code>property</code> from this <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.</TD>
217 </TR>
218 <TR BGCOLOR="white" CLASS="TableRowColor">
219 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
220 <CODE>abstract &nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
221 <TD><CODE><B>LongSerializationPolicy.</B><B><A HREF="../../../../com/google/gson/LongSerializationPolicy.html#serialize(java.lang.Long)">serialize</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</A>&nbsp;value)</CODE>
222
223 <BR>
224 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Serialize this <code>value</code> using this serialization policy.</TD>
225 </TR>
226 <TR BGCOLOR="white" CLASS="TableRowColor">
227 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
228 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
229 <TD><CODE><B>JsonSerializationContext.</B><B><A HREF="../../../../com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object)">serialize</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</CODE>
230
231 <BR>
232 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default serialization on the specified object.</TD>
233 </TR>
234 <TR BGCOLOR="white" CLASS="TableRowColor">
235 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
236 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
237 <TD><CODE><B>JsonSerializationContext.</B><B><A HREF="../../../../com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object, java.lang.reflect.Type)">serialize</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
238 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</CODE>
239
240 <BR>
241 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default serialization on the specified object passing the specific type information.</TD>
242 </TR>
243 <TR BGCOLOR="white" CLASS="TableRowColor">
244 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
245 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
246 <TD><CODE><B>JsonSerializer.</B><B><A HREF="../../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)">serialize</A></B>(<A HREF="../../../../com/google/gson/JsonSerializer.html" title="type parameter in JsonSerializer">T</A>&nbsp;src,
247 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
248 <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A>&nbsp;context)</CODE>
249
250 <BR>
251 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during serialization when it encounters a field of the
252 specified type.</TD>
253 </TR>
254 <TR BGCOLOR="white" CLASS="TableRowColor">
255 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
256 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
257 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#set(int, com.google.gson.JsonElement)">set</A></B>(int&nbsp;index,
258 <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
259
260 <BR>
261 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Replaces the element at the specified position in this array with the specified element.</TD>
262 </TR>
263 <TR BGCOLOR="white" CLASS="TableRowColor">
264 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
265 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
266 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJsonTree(java.lang.Object)">toJsonTree</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src)</CODE>
267
268 <BR>
269 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object into its equivalent representation as a tree of
270 <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
271 </TR>
272 <TR BGCOLOR="white" CLASS="TableRowColor">
273 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
274 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
275 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJsonTree(java.lang.Object, java.lang.reflect.Type)">toJsonTree</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
276 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc)</CODE>
277
278 <BR>
279 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object, including those of generic types, into its
280 equivalent representation as a tree of <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
281 </TR>
282 <TR BGCOLOR="white" CLASS="TableRowColor">
283 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
284 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
285 <TD><CODE><B>TypeAdapter.</B><B><A HREF="../../../../com/google/gson/TypeAdapter.html#toJsonTree(T)">toJsonTree</A></B>(<A HREF="../../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</CODE>
286
287 <BR>
288 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts <code>value</code> to a JSON tree.</TD>
289 </TR>
290 </TABLE>
291 &nbsp;
292 <P>
293
294 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
295 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
296 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return types with arguments of type <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></FONT></TH>
297 </TR>
298 <TR BGCOLOR="white" CLASS="TableRowColor">
299 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
300 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Map.Entry.html?is-external=true" title="class or interface in java.util">Map.Entry</A>&lt;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>,<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;&gt;</CODE></FONT></TD>
301 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#entrySet()">entrySet</A></B>()</CODE>
302
303 <BR>
304 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a set of members of this object.</TD>
305 </TR>
306 <TR BGCOLOR="white" CLASS="TableRowColor">
307 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
308 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&gt;</CODE></FONT></TD>
309 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#iterator()">iterator</A></B>()</CODE>
310
311 <BR>
312 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an iterator to navigate the elemetns of the array.</TD>
313 </TR>
314 </TABLE>
315 &nbsp;
316 <P>
317
318 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
319 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
320 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></FONT></TH>
321 </TR>
322 <TR BGCOLOR="white" CLASS="TableRowColor">
323 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
324 <CODE>&nbsp;void</CODE></FONT></TD>
325 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#add(com.google.gson.JsonElement)">add</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
326
327 <BR>
328 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds the specified element to self.</TD>
329 </TR>
330 <TR BGCOLOR="white" CLASS="TableRowColor">
331 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
332 <CODE>&nbsp;void</CODE></FONT></TD>
333 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#add(java.lang.String, com.google.gson.JsonElement)">add</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;property,
334 <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;value)</CODE>
335
336 <BR>
337 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Adds a member, which is a name-value pair, to self.</TD>
338 </TR>
339 <TR BGCOLOR="white" CLASS="TableRowColor">
340 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
341 <CODE>&nbsp;boolean</CODE></FONT></TD>
342 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#contains(com.google.gson.JsonElement)">contains</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
343
344 <BR>
345 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if this array contains the specified element.</TD>
346 </TR>
347 <TR BGCOLOR="white" CLASS="TableRowColor">
348 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
349 <CODE>
350 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
351 <TR ALIGN="right" VALIGN="">
352 <TD NOWRAP><FONT SIZE="-1">
353 <CODE>&lt;T&gt; T</CODE></FONT></TD>
354 </TR>
355 </TABLE>
356 </CODE></FONT></TD>
357 <TD><CODE><B>JsonDeserializationContext.</B><B><A HREF="../../../../com/google/gson/JsonDeserializationContext.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type)">deserialize</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
358 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
359
360 <BR>
361 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default deserialization on the specified object.</TD>
362 </TR>
363 <TR BGCOLOR="white" CLASS="TableRowColor">
364 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
365 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonDeserializer.html" title="type parameter in JsonDeserializer">T</A></CODE></FONT></TD>
366 <TD><CODE><B>JsonDeserializer.</B><B><A HREF="../../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)">deserialize</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
367 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT,
368 <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A>&nbsp;context)</CODE>
369
370 <BR>
371 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during deserialization when it encounters a field of the
372 specified type.</TD>
373 </TR>
374 <TR BGCOLOR="white" CLASS="TableRowColor">
375 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
376 <CODE>
377 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
378 <TR ALIGN="right" VALIGN="">
379 <TD NOWRAP><FONT SIZE="-1">
380 <CODE>&lt;T&gt; T</CODE></FONT></TD>
381 </TR>
382 </TABLE>
383 </CODE></FONT></TD>
384 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.Class)">fromJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
385 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
386
387 <BR>
388 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified parse tree into an object of the
389 specified type.</TD>
390 </TR>
391 <TR BGCOLOR="white" CLASS="TableRowColor">
392 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
393 <CODE>
394 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
395 <TR ALIGN="right" VALIGN="">
396 <TD NOWRAP><FONT SIZE="-1">
397 <CODE>&lt;T&gt; T</CODE></FONT></TD>
398 </TR>
399 </TABLE>
400 </CODE></FONT></TD>
401 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
402 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
403
404 <BR>
405 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified parse tree into an object of the
406 specified type.</TD>
407 </TR>
408 <TR BGCOLOR="white" CLASS="TableRowColor">
409 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
410 <CODE>&nbsp;<A HREF="../../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A></CODE></FONT></TD>
411 <TD><CODE><B>TypeAdapter.</B><B><A HREF="../../../../com/google/gson/TypeAdapter.html#fromJsonTree(com.google.gson.JsonElement)">fromJsonTree</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonTree)</CODE>
412
413 <BR>
414 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts <code>jsonTree</code> to a Java object.</TD>
415 </TR>
416 <TR BGCOLOR="white" CLASS="TableRowColor">
417 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
418 <CODE>&nbsp;boolean</CODE></FONT></TD>
419 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#remove(com.google.gson.JsonElement)">remove</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
420
421 <BR>
422 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the first occurrence of the specified element from this array, if it is present.</TD>
423 </TR>
424 <TR BGCOLOR="white" CLASS="TableRowColor">
425 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
426 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
427 <TD><CODE><B>JsonArray.</B><B><A HREF="../../../../com/google/gson/JsonArray.html#set(int, com.google.gson.JsonElement)">set</A></B>(int&nbsp;index,
428 <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;element)</CODE>
429
430 <BR>
431 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Replaces the element at the specified position in this array with the specified element.</TD>
432 </TR>
433 <TR BGCOLOR="white" CLASS="TableRowColor">
434 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
435 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
436 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement)">toJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement)</CODE>
437
438 <BR>
439 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts a tree of <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s into its equivalent JSON representation.</TD>
440 </TR>
441 <TR BGCOLOR="white" CLASS="TableRowColor">
442 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
443 <CODE>&nbsp;void</CODE></FONT></TD>
444 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, java.lang.Appendable)">toJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
445 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
446
447 <BR>
448 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes out the equivalent JSON for a tree of <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
449 </TR>
450 <TR BGCOLOR="white" CLASS="TableRowColor">
451 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
452 <CODE>&nbsp;void</CODE></FONT></TD>
453 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
454 <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
455
456 <BR>
457 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON for <code>jsonElement</code> to <code>writer</code>.</TD>
458 </TR>
459 </TABLE>
460 &nbsp;
461 <P>
462 <HR>
463
464
465 <!-- ======= START OF BOTTOM NAVBAR ====== -->
466 <A NAME="navbar_bottom"><!-- --></A>
467 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
468 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
469 <TR>
470 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
471 <A NAME="navbar_bottom_firstrow"><!-- --></A>
472 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
473 <TR ALIGN="center" VALIGN="top">
474 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
475 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
476 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
477 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
478 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
479 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
480 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
481 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
482 </TR>
483 </TABLE>
484 </TD>
485 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
486 </EM>
487 </TD>
488 </TR>
489
490 <TR>
491 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
492 &nbsp;PREV&nbsp;
493 &nbsp;NEXT</FONT></TD>
494 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
495 <A HREF="../../../../index.html?com/google/gson//class-useJsonElement.html" target="_top"><B>FRAMES</B></A> &nbsp;
496 &nbsp;<A HREF="JsonElement.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
497 &nbsp;<SCRIPT type="text/javascript">
498 <!--
499 if(window==top) {
500 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
501 }
502 //-->
503 </SCRIPT>
504 <NOSCRIPT>
505 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
506 </NOSCRIPT>
507
508
509 </FONT></TD>
510 </TR>
511 </TABLE>
512 <A NAME="skip-navbar_bottom"></A>
513 <!-- ======== END OF BOTTOM NAVBAR ======= -->
514
515 <HR>
516 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
517 </BODY>
518 </HTML>
+0
-290
gson/docs/javadocs/com/google/gson/class-use/JsonIOException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonIOException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonIOException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonIOException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonIOException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonIOException</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that throw <A HREF="../../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>
117 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
118 <TR ALIGN="right" VALIGN="">
119 <TD NOWRAP><FONT SIZE="-1">
120 <CODE>&lt;T&gt; T</CODE></FONT></TD>
121 </TR>
122 </TABLE>
123 </CODE></FONT></TD>
124 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(com.google.gson.stream.JsonReader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;reader,
125 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads the next JSON value from <code>reader</code> and convert it to an object
129 of type <code>typeOfT</code>.</TD>
130 </TR>
131 <TR BGCOLOR="white" CLASS="TableRowColor">
132 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
133 <CODE>
134 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
135 <TR ALIGN="right" VALIGN="">
136 <TD NOWRAP><FONT SIZE="-1">
137 <CODE>&lt;T&gt; T</CODE></FONT></TD>
138 </TR>
139 </TABLE>
140 </CODE></FONT></TD>
141 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
142 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified reader into an object of the
146 specified class.</TD>
147 </TR>
148 <TR BGCOLOR="white" CLASS="TableRowColor">
149 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
150 <CODE>
151 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
152 <TR ALIGN="right" VALIGN="">
153 <TD NOWRAP><FONT SIZE="-1">
154 <CODE>&lt;T&gt; T</CODE></FONT></TD>
155 </TR>
156 </TABLE>
157 </CODE></FONT></TD>
158 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
159 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
160
161 <BR>
162 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified reader into an object of the
163 specified type.</TD>
164 </TR>
165 <TR BGCOLOR="white" CLASS="TableRowColor">
166 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
167 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
168 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(com.google.gson.stream.JsonReader)">parse</A></B>(<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;json)</CODE>
169
170 <BR>
171 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next value from the JSON stream as a parse tree.</TD>
172 </TR>
173 <TR BGCOLOR="white" CLASS="TableRowColor">
174 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
175 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
176 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(java.io.Reader)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json)</CODE>
177
178 <BR>
179 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
180 </TR>
181 <TR BGCOLOR="white" CLASS="TableRowColor">
182 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
183 <CODE>&nbsp;void</CODE></FONT></TD>
184 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, java.lang.Appendable)">toJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
185 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
186
187 <BR>
188 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes out the equivalent JSON for a tree of <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.</TD>
189 </TR>
190 <TR BGCOLOR="white" CLASS="TableRowColor">
191 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
192 <CODE>&nbsp;void</CODE></FONT></TD>
193 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
194 <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
195
196 <BR>
197 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON for <code>jsonElement</code> to <code>writer</code>.</TD>
198 </TR>
199 <TR BGCOLOR="white" CLASS="TableRowColor">
200 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
201 <CODE>&nbsp;void</CODE></FONT></TD>
202 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.Appendable)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
203 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
204
205 <BR>
206 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object into its equivalent Json representation.</TD>
207 </TR>
208 <TR BGCOLOR="white" CLASS="TableRowColor">
209 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
210 <CODE>&nbsp;void</CODE></FONT></TD>
211 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, java.lang.Appendable)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
212 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
213 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Appendable.html?is-external=true" title="class or interface in java.lang">Appendable</A>&nbsp;writer)</CODE>
214
215 <BR>
216 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method serializes the specified object, including those of generic types, into its
217 equivalent Json representation.</TD>
218 </TR>
219 <TR BGCOLOR="white" CLASS="TableRowColor">
220 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
221 <CODE>&nbsp;void</CODE></FONT></TD>
222 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
223 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
224 <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
225
226 <BR>
227 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON representation of <code>src</code> of type <code>typeOfSrc</code> to
228 <code>writer</code>.</TD>
229 </TR>
230 </TABLE>
231 &nbsp;
232 <P>
233 <HR>
234
235
236 <!-- ======= START OF BOTTOM NAVBAR ====== -->
237 <A NAME="navbar_bottom"><!-- --></A>
238 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
239 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
240 <TR>
241 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
242 <A NAME="navbar_bottom_firstrow"><!-- --></A>
243 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
244 <TR ALIGN="center" VALIGN="top">
245 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
246 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
247 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
248 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
249 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
250 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
251 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
252 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
253 </TR>
254 </TABLE>
255 </TD>
256 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
257 </EM>
258 </TD>
259 </TR>
260
261 <TR>
262 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
263 &nbsp;PREV&nbsp;
264 &nbsp;NEXT</FONT></TD>
265 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
266 <A HREF="../../../../index.html?com/google/gson//class-useJsonIOException.html" target="_top"><B>FRAMES</B></A> &nbsp;
267 &nbsp;<A HREF="JsonIOException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
268 &nbsp;<SCRIPT type="text/javascript">
269 <!--
270 if(window==top) {
271 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
272 }
273 //-->
274 </SCRIPT>
275 <NOSCRIPT>
276 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
277 </NOSCRIPT>
278
279
280 </FONT></TD>
281 </TR>
282 </TABLE>
283 <A NAME="skip-navbar_bottom"></A>
284 <!-- ======== END OF BOTTOM NAVBAR ======= -->
285
286 <HR>
287 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
288 </BODY>
289 </HTML>
+0
-198
gson/docs/javadocs/com/google/gson/class-use/JsonNull.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonNull (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonNull (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonNull.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonNull.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonNull</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Fields in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> declared as <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></CODE></FONT></TD>
117 <TD><CODE><B>JsonNull.</B><B><A HREF="../../../../com/google/gson/JsonNull.html#INSTANCE">INSTANCE</A></B></CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;singleton for JsonNull</TD>
121 </TR>
122 </TABLE>
123 &nbsp;
124 <P>
125
126 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
127 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
128 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></FONT></TH>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></CODE></FONT></TD>
133 <TD><CODE><B>JsonElement.</B><B><A HREF="../../../../com/google/gson/JsonElement.html#getAsJsonNull()">getAsJsonNull</A></B>()</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.</TD>
137 </TR>
138 </TABLE>
139 &nbsp;
140 <P>
141 <HR>
142
143
144 <!-- ======= START OF BOTTOM NAVBAR ====== -->
145 <A NAME="navbar_bottom"><!-- --></A>
146 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
147 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
148 <TR>
149 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
150 <A NAME="navbar_bottom_firstrow"><!-- --></A>
151 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
152 <TR ALIGN="center" VALIGN="top">
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
155 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
156 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
157 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
158 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
159 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
160 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
161 </TR>
162 </TABLE>
163 </TD>
164 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
165 </EM>
166 </TD>
167 </TR>
168
169 <TR>
170 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
171 &nbsp;PREV&nbsp;
172 &nbsp;NEXT</FONT></TD>
173 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
174 <A HREF="../../../../index.html?com/google/gson//class-useJsonNull.html" target="_top"><B>FRAMES</B></A> &nbsp;
175 &nbsp;<A HREF="JsonNull.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
176 &nbsp;<SCRIPT type="text/javascript">
177 <!--
178 if(window==top) {
179 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
180 }
181 //-->
182 </SCRIPT>
183 <NOSCRIPT>
184 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
185 </NOSCRIPT>
186
187
188 </FONT></TD>
189 </TR>
190 </TABLE>
191 <A NAME="skip-navbar_bottom"></A>
192 <!-- ======== END OF BOTTOM NAVBAR ======= -->
193
194 <HR>
195 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
196 </BODY>
197 </HTML>
+0
-190
gson/docs/javadocs/com/google/gson/class-use/JsonObject.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonObject (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonObject (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonObject.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonObject.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonObject</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></CODE></FONT></TD>
117 <TD><CODE><B>JsonElement.</B><B><A HREF="../../../../com/google/gson/JsonElement.html#getAsJsonObject()">getAsJsonObject</A></B>()</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></CODE></FONT></TD>
125 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#getAsJsonObject(java.lang.String)">getAsJsonObject</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to get the specified member as a JsonObject.</TD>
129 </TR>
130 </TABLE>
131 &nbsp;
132 <P>
133 <HR>
134
135
136 <!-- ======= START OF BOTTOM NAVBAR ====== -->
137 <A NAME="navbar_bottom"><!-- --></A>
138 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
139 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
140 <TR>
141 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
142 <A NAME="navbar_bottom_firstrow"><!-- --></A>
143 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
144 <TR ALIGN="center" VALIGN="top">
145 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
146 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
148 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
149 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
150 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
153 </TR>
154 </TABLE>
155 </TD>
156 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
157 </EM>
158 </TD>
159 </TR>
160
161 <TR>
162 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
163 &nbsp;PREV&nbsp;
164 &nbsp;NEXT</FONT></TD>
165 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
166 <A HREF="../../../../index.html?com/google/gson//class-useJsonObject.html" target="_top"><B>FRAMES</B></A> &nbsp;
167 &nbsp;<A HREF="JsonObject.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
168 &nbsp;<SCRIPT type="text/javascript">
169 <!--
170 if(window==top) {
171 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
172 }
173 //-->
174 </SCRIPT>
175 <NOSCRIPT>
176 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
177 </NOSCRIPT>
178
179
180 </FONT></TD>
181 </TR>
182 </TABLE>
183 <A NAME="skip-navbar_bottom"></A>
184 <!-- ======== END OF BOTTOM NAVBAR ======= -->
185
186 <HR>
187 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
188 </BODY>
189 </HTML>
+0
-235
gson/docs/javadocs/com/google/gson/class-use/JsonParseException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonParseException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonParseException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonParseException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonParseException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonParseException</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Subclasses of <A HREF="../../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;class</CODE></FONT></TD>
117 <TD><CODE><B><A HREF="../../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></B></CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This exception is raised when Gson was unable to read an input stream
121 or write to one.</TD>
122 </TR>
123 <TR BGCOLOR="white" CLASS="TableRowColor">
124 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
125 <CODE>&nbsp;class</CODE></FONT></TD>
126 <TD><CODE><B><A HREF="../../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></B></CODE>
127
128 <BR>
129 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This exception is raised when Gson attempts to read (or write) a malformed
130 JSON element.</TD>
131 </TR>
132 </TABLE>
133 &nbsp;
134 <P>
135
136 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
137 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
138 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that throw <A HREF="../../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></FONT></TH>
139 </TR>
140 <TR BGCOLOR="white" CLASS="TableRowColor">
141 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
142 <CODE>
143 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
144 <TR ALIGN="right" VALIGN="">
145 <TD NOWRAP><FONT SIZE="-1">
146 <CODE>&lt;T&gt; T</CODE></FONT></TD>
147 </TR>
148 </TABLE>
149 </CODE></FONT></TD>
150 <TD><CODE><B>JsonDeserializationContext.</B><B><A HREF="../../../../com/google/gson/JsonDeserializationContext.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type)">deserialize</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
151 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
152
153 <BR>
154 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Invokes default deserialization on the specified object.</TD>
155 </TR>
156 <TR BGCOLOR="white" CLASS="TableRowColor">
157 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
158 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonDeserializer.html" title="type parameter in JsonDeserializer">T</A></CODE></FONT></TD>
159 <TD><CODE><B>JsonDeserializer.</B><B><A HREF="../../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)">deserialize</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
160 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT,
161 <A HREF="../../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A>&nbsp;context)</CODE>
162
163 <BR>
164 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during deserialization when it encounters a field of the
165 specified type.</TD>
166 </TR>
167 <TR BGCOLOR="white" CLASS="TableRowColor">
168 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
169 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
170 <TD><CODE><B>JsonStreamParser.</B><B><A HREF="../../../../com/google/gson/JsonStreamParser.html#next()">next</A></B>()</CODE>
171
172 <BR>
173 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next available <A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> on the reader.</TD>
174 </TR>
175 </TABLE>
176 &nbsp;
177 <P>
178 <HR>
179
180
181 <!-- ======= START OF BOTTOM NAVBAR ====== -->
182 <A NAME="navbar_bottom"><!-- --></A>
183 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
184 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
185 <TR>
186 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
187 <A NAME="navbar_bottom_firstrow"><!-- --></A>
188 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
189 <TR ALIGN="center" VALIGN="top">
190 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
191 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
192 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
193 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
194 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
195 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
196 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
197 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
198 </TR>
199 </TABLE>
200 </TD>
201 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
202 </EM>
203 </TD>
204 </TR>
205
206 <TR>
207 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
208 &nbsp;PREV&nbsp;
209 &nbsp;NEXT</FONT></TD>
210 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
211 <A HREF="../../../../index.html?com/google/gson//class-useJsonParseException.html" target="_top"><B>FRAMES</B></A> &nbsp;
212 &nbsp;<A HREF="JsonParseException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
213 &nbsp;<SCRIPT type="text/javascript">
214 <!--
215 if(window==top) {
216 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
217 }
218 //-->
219 </SCRIPT>
220 <NOSCRIPT>
221 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
222 </NOSCRIPT>
223
224
225 </FONT></TD>
226 </TR>
227 </TABLE>
228 <A NAME="skip-navbar_bottom"></A>
229 <!-- ======== END OF BOTTOM NAVBAR ======= -->
230
231 <HR>
232 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
233 </BODY>
234 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/class-use/JsonParser.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonParser (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonParser (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonParser</B></H2>
85 </CENTER>
86 No usage of com.google.gson.JsonParser
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../index.html?com/google/gson//class-useJsonParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="JsonParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-190
gson/docs/javadocs/com/google/gson/class-use/JsonPrimitive.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonPrimitive (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonPrimitive (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonPrimitive.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonPrimitive.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonPrimitive</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></CODE></FONT></TD>
117 <TD><CODE><B>JsonElement.</B><B><A HREF="../../../../com/google/gson/JsonElement.html#getAsJsonPrimitive()">getAsJsonPrimitive</A></B>()</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;convenience method to get this element as a <A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></CODE></FONT></TD>
125 <TD><CODE><B>JsonObject.</B><B><A HREF="../../../../com/google/gson/JsonObject.html#getAsJsonPrimitive(java.lang.String)">getAsJsonPrimitive</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;memberName)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Convenience method to get the specified member as a JsonPrimitive element.</TD>
129 </TR>
130 </TABLE>
131 &nbsp;
132 <P>
133 <HR>
134
135
136 <!-- ======= START OF BOTTOM NAVBAR ====== -->
137 <A NAME="navbar_bottom"><!-- --></A>
138 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
139 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
140 <TR>
141 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
142 <A NAME="navbar_bottom_firstrow"><!-- --></A>
143 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
144 <TR ALIGN="center" VALIGN="top">
145 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
146 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
148 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
149 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
150 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
153 </TR>
154 </TABLE>
155 </TD>
156 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
157 </EM>
158 </TD>
159 </TR>
160
161 <TR>
162 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
163 &nbsp;PREV&nbsp;
164 &nbsp;NEXT</FONT></TD>
165 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
166 <A HREF="../../../../index.html?com/google/gson//class-useJsonPrimitive.html" target="_top"><B>FRAMES</B></A> &nbsp;
167 &nbsp;<A HREF="JsonPrimitive.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
168 &nbsp;<SCRIPT type="text/javascript">
169 <!--
170 if(window==top) {
171 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
172 }
173 //-->
174 </SCRIPT>
175 <NOSCRIPT>
176 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
177 </NOSCRIPT>
178
179
180 </FONT></TD>
181 </TR>
182 </TABLE>
183 <A NAME="skip-navbar_bottom"></A>
184 <!-- ======== END OF BOTTOM NAVBAR ======= -->
185
186 <HR>
187 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
188 </BODY>
189 </HTML>
+0
-185
gson/docs/javadocs/com/google/gson/class-use/JsonSerializationContext.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.JsonSerializationContext (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.JsonSerializationContext (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonSerializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonSerializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.JsonSerializationContext</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
117 <TD><CODE><B>JsonSerializer.</B><B><A HREF="../../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)">serialize</A></B>(<A HREF="../../../../com/google/gson/JsonSerializer.html" title="type parameter in JsonSerializer">T</A>&nbsp;src,
118 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
119 <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A>&nbsp;context)</CODE>
120
121 <BR>
122 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gson invokes this call-back method during serialization when it encounters a field of the
123 specified type.</TD>
124 </TR>
125 </TABLE>
126 &nbsp;
127 <P>
128 <HR>
129
130
131 <!-- ======= START OF BOTTOM NAVBAR ====== -->
132 <A NAME="navbar_bottom"><!-- --></A>
133 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
134 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
135 <TR>
136 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
137 <A NAME="navbar_bottom_firstrow"><!-- --></A>
138 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
139 <TR ALIGN="center" VALIGN="top">
140 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
141 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
142 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
143 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
144 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
145 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
146 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
148 </TR>
149 </TABLE>
150 </TD>
151 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
152 </EM>
153 </TD>
154 </TR>
155
156 <TR>
157 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
158 &nbsp;PREV&nbsp;
159 &nbsp;NEXT</FONT></TD>
160 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
161 <A HREF="../../../../index.html?com/google/gson//class-useJsonSerializationContext.html" target="_top"><B>FRAMES</B></A> &nbsp;
162 &nbsp;<A HREF="JsonSerializationContext.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
163 &nbsp;<SCRIPT type="text/javascript">
164 <!--
165 if(window==top) {
166 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
167 }
168 //-->
169 </SCRIPT>
170 <NOSCRIPT>
171 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
172 </NOSCRIPT>
173
174
175 </FONT></TD>
176 </TR>
177 </TABLE>
178 <A NAME="skip-navbar_bottom"></A>
179 <!-- ======== END OF BOTTOM NAVBAR ======= -->
180
181 <HR>
182 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
183 </BODY>
184 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/class-use/JsonSerializer.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.JsonSerializer (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.JsonSerializer (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonSerializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonSerializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.JsonSerializer</B></H2>
85 </CENTER>
86 No usage of com.google.gson.JsonSerializer
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../index.html?com/google/gson//class-useJsonSerializer.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="JsonSerializer.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/class-use/JsonStreamParser.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonStreamParser (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonStreamParser (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonStreamParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonStreamParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonStreamParser</B></H2>
85 </CENTER>
86 No usage of com.google.gson.JsonStreamParser
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../index.html?com/google/gson//class-useJsonStreamParser.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="JsonStreamParser.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-315
gson/docs/javadocs/com/google/gson/class-use/JsonSyntaxException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.JsonSyntaxException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.JsonSyntaxException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useJsonSyntaxException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonSyntaxException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.JsonSyntaxException</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that throw <A HREF="../../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>
117 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
118 <TR ALIGN="right" VALIGN="">
119 <TD NOWRAP><FONT SIZE="-1">
120 <CODE>&lt;T&gt; T</CODE></FONT></TD>
121 </TR>
122 </TABLE>
123 </CODE></FONT></TD>
124 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.Class)">fromJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
125 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified parse tree into an object of the
129 specified type.</TD>
130 </TR>
131 <TR BGCOLOR="white" CLASS="TableRowColor">
132 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
133 <CODE>
134 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
135 <TR ALIGN="right" VALIGN="">
136 <TD NOWRAP><FONT SIZE="-1">
137 <CODE>&lt;T&gt; T</CODE></FONT></TD>
138 </TR>
139 </TABLE>
140 </CODE></FONT></TD>
141 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;json,
142 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified parse tree into an object of the
146 specified type.</TD>
147 </TR>
148 <TR BGCOLOR="white" CLASS="TableRowColor">
149 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
150 <CODE>
151 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
152 <TR ALIGN="right" VALIGN="">
153 <TD NOWRAP><FONT SIZE="-1">
154 <CODE>&lt;T&gt; T</CODE></FONT></TD>
155 </TR>
156 </TABLE>
157 </CODE></FONT></TD>
158 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(com.google.gson.stream.JsonReader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;reader,
159 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
160
161 <BR>
162 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads the next JSON value from <code>reader</code> and convert it to an object
163 of type <code>typeOfT</code>.</TD>
164 </TR>
165 <TR BGCOLOR="white" CLASS="TableRowColor">
166 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
167 <CODE>
168 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
169 <TR ALIGN="right" VALIGN="">
170 <TD NOWRAP><FONT SIZE="-1">
171 <CODE>&lt;T&gt; T</CODE></FONT></TD>
172 </TR>
173 </TABLE>
174 </CODE></FONT></TD>
175 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
176 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
177
178 <BR>
179 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified reader into an object of the
180 specified class.</TD>
181 </TR>
182 <TR BGCOLOR="white" CLASS="TableRowColor">
183 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
184 <CODE>
185 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
186 <TR ALIGN="right" VALIGN="">
187 <TD NOWRAP><FONT SIZE="-1">
188 <CODE>&lt;T&gt; T</CODE></FONT></TD>
189 </TR>
190 </TABLE>
191 </CODE></FONT></TD>
192 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json,
193 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
194
195 <BR>
196 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the Json read from the specified reader into an object of the
197 specified type.</TD>
198 </TR>
199 <TR BGCOLOR="white" CLASS="TableRowColor">
200 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
201 <CODE>
202 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
203 <TR ALIGN="right" VALIGN="">
204 <TD NOWRAP><FONT SIZE="-1">
205 <CODE>&lt;T&gt; T</CODE></FONT></TD>
206 </TR>
207 </TABLE>
208 </CODE></FONT></TD>
209 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json,
210 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;classOfT)</CODE>
211
212 <BR>
213 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the specified Json into an object of the specified class.</TD>
214 </TR>
215 <TR BGCOLOR="white" CLASS="TableRowColor">
216 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
217 <CODE>
218 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
219 <TR ALIGN="right" VALIGN="">
220 <TD NOWRAP><FONT SIZE="-1">
221 <CODE>&lt;T&gt; T</CODE></FONT></TD>
222 </TR>
223 </TABLE>
224 </CODE></FONT></TD>
225 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json,
226 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
227
228 <BR>
229 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method deserializes the specified Json into an object of the specified type.</TD>
230 </TR>
231 <TR BGCOLOR="white" CLASS="TableRowColor">
232 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
233 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
234 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(com.google.gson.stream.JsonReader)">parse</A></B>(<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;json)</CODE>
235
236 <BR>
237 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next value from the JSON stream as a parse tree.</TD>
238 </TR>
239 <TR BGCOLOR="white" CLASS="TableRowColor">
240 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
241 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
242 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(java.io.Reader)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;json)</CODE>
243
244 <BR>
245 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
246 </TR>
247 <TR BGCOLOR="white" CLASS="TableRowColor">
248 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
249 <CODE>&nbsp;<A HREF="../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
250 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../com/google/gson/JsonParser.html#parse(java.lang.String)">parse</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;json)</CODE>
251
252 <BR>
253 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Parses the specified JSON string into a parse tree</TD>
254 </TR>
255 </TABLE>
256 &nbsp;
257 <P>
258 <HR>
259
260
261 <!-- ======= START OF BOTTOM NAVBAR ====== -->
262 <A NAME="navbar_bottom"><!-- --></A>
263 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
264 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
265 <TR>
266 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
267 <A NAME="navbar_bottom_firstrow"><!-- --></A>
268 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
269 <TR ALIGN="center" VALIGN="top">
270 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
271 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
272 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
273 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
274 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
275 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
276 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
277 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
278 </TR>
279 </TABLE>
280 </TD>
281 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
282 </EM>
283 </TD>
284 </TR>
285
286 <TR>
287 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
288 &nbsp;PREV&nbsp;
289 &nbsp;NEXT</FONT></TD>
290 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
291 <A HREF="../../../../index.html?com/google/gson//class-useJsonSyntaxException.html" target="_top"><B>FRAMES</B></A> &nbsp;
292 &nbsp;<A HREF="JsonSyntaxException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
293 &nbsp;<SCRIPT type="text/javascript">
294 <!--
295 if(window==top) {
296 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
297 }
298 //-->
299 </SCRIPT>
300 <NOSCRIPT>
301 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
302 </NOSCRIPT>
303
304
305 </FONT></TD>
306 </TR>
307 </TABLE>
308 <A NAME="skip-navbar_bottom"></A>
309 <!-- ======== END OF BOTTOM NAVBAR ======= -->
310
311 <HR>
312 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
313 </BODY>
314 </HTML>
+0
-208
gson/docs/javadocs/com/google/gson/class-use/LongSerializationPolicy.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.LongSerializationPolicy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.LongSerializationPolicy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useLongSerializationPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="LongSerializationPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.LongSerializationPolicy</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A></CODE></FONT></TD>
117 <TD><CODE><B>LongSerializationPolicy.</B><B><A HREF="../../../../com/google/gson/LongSerializationPolicy.html#valueOf(java.lang.String)">valueOf</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
118
119 <BR>
120 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the enum constant of this type with the specified name.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
124 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>[]</CODE></FONT></TD>
125 <TD><CODE><B>LongSerializationPolicy.</B><B><A HREF="../../../../com/google/gson/LongSerializationPolicy.html#values()">values</A></B>()</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an array containing the constants of this enum type, in
129 the order they are declared.</TD>
130 </TR>
131 </TABLE>
132 &nbsp;
133 <P>
134
135 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
136 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
137 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A></FONT></TH>
138 </TR>
139 <TR BGCOLOR="white" CLASS="TableRowColor">
140 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
141 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
142 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#setLongSerializationPolicy(com.google.gson.LongSerializationPolicy)">setLongSerializationPolicy</A></B>(<A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>&nbsp;serializationPolicy)</CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configures Gson to apply a specific serialization policy for <code>Long</code> and <code>long</code>
146 objects.</TD>
147 </TR>
148 </TABLE>
149 &nbsp;
150 <P>
151 <HR>
152
153
154 <!-- ======= START OF BOTTOM NAVBAR ====== -->
155 <A NAME="navbar_bottom"><!-- --></A>
156 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
157 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
158 <TR>
159 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
160 <A NAME="navbar_bottom_firstrow"><!-- --></A>
161 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
162 <TR ALIGN="center" VALIGN="top">
163 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
164 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
165 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
166 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
167 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
168 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
169 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
170 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
171 </TR>
172 </TABLE>
173 </TD>
174 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
175 </EM>
176 </TD>
177 </TR>
178
179 <TR>
180 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
181 &nbsp;PREV&nbsp;
182 &nbsp;NEXT</FONT></TD>
183 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
184 <A HREF="../../../../index.html?com/google/gson//class-useLongSerializationPolicy.html" target="_top"><B>FRAMES</B></A> &nbsp;
185 &nbsp;<A HREF="LongSerializationPolicy.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
186 &nbsp;<SCRIPT type="text/javascript">
187 <!--
188 if(window==top) {
189 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
190 }
191 //-->
192 </SCRIPT>
193 <NOSCRIPT>
194 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
195 </NOSCRIPT>
196
197
198 </FONT></TD>
199 </TR>
200 </TABLE>
201 <A NAME="skip-navbar_bottom"></A>
202 <!-- ======== END OF BOTTOM NAVBAR ======= -->
203
204 <HR>
205 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
206 </BODY>
207 </HTML>
+0
-245
gson/docs/javadocs/com/google/gson/class-use/TypeAdapter.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.TypeAdapter (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.TypeAdapter (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useTypeAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="TypeAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.TypeAdapter</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> that return <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>
117 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
118 <TR ALIGN="right" VALIGN="">
119 <TD NOWRAP><FONT SIZE="-1">
120 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
121 </TR>
122 </TABLE>
123 </CODE></FONT></TD>
124 <TD><CODE><B>TypeAdapterFactory.</B><B><A HREF="../../../../com/google/gson/TypeAdapterFactory.html#create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)">create</A></B>(<A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>&nbsp;gson,
125 <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a type adapter for <code>type</code>, or null if this factory doesn't
129 support <code>type</code>.</TD>
130 </TR>
131 <TR BGCOLOR="white" CLASS="TableRowColor">
132 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
133 <CODE>
134 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
135 <TR ALIGN="right" VALIGN="">
136 <TD NOWRAP><FONT SIZE="-1">
137 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
138 </TR>
139 </TABLE>
140 </CODE></FONT></TD>
141 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#getAdapter(java.lang.Class)">getAdapter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;type)</CODE>
142
143 <BR>
144 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type adapter for <code></code> type.</TD>
145 </TR>
146 <TR BGCOLOR="white" CLASS="TableRowColor">
147 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
148 <CODE>
149 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
150 <TR ALIGN="right" VALIGN="">
151 <TD NOWRAP><FONT SIZE="-1">
152 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
153 </TR>
154 </TABLE>
155 </CODE></FONT></TD>
156 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#getAdapter(com.google.gson.reflect.TypeToken)">getAdapter</A></B>(<A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
157
158 <BR>
159 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type adapter for <code></code> type.</TD>
160 </TR>
161 <TR BGCOLOR="white" CLASS="TableRowColor">
162 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
163 <CODE>
164 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
165 <TR ALIGN="right" VALIGN="">
166 <TD NOWRAP><FONT SIZE="-1">
167 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
168 </TR>
169 </TABLE>
170 </CODE></FONT></TD>
171 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)">getDelegateAdapter</A></B>(<A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;skipPast,
172 <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
173
174 <BR>
175 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method is used to get an alternate type adapter for the specified type.</TD>
176 </TR>
177 <TR BGCOLOR="white" CLASS="TableRowColor">
178 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
179 <CODE>&nbsp;<A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;<A HREF="../../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&gt;</CODE></FONT></TD>
180 <TD><CODE><B>TypeAdapter.</B><B><A HREF="../../../../com/google/gson/TypeAdapter.html#nullSafe()">nullSafe</A></B>()</CODE>
181
182 <BR>
183 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This wrapper method is used to make a type adapter null tolerant.</TD>
184 </TR>
185 </TABLE>
186 &nbsp;
187 <P>
188 <HR>
189
190
191 <!-- ======= START OF BOTTOM NAVBAR ====== -->
192 <A NAME="navbar_bottom"><!-- --></A>
193 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
194 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
195 <TR>
196 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
197 <A NAME="navbar_bottom_firstrow"><!-- --></A>
198 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
199 <TR ALIGN="center" VALIGN="top">
200 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
201 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
202 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
203 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
204 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
205 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
206 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
207 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
208 </TR>
209 </TABLE>
210 </TD>
211 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
212 </EM>
213 </TD>
214 </TR>
215
216 <TR>
217 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
218 &nbsp;PREV&nbsp;
219 &nbsp;NEXT</FONT></TD>
220 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
221 <A HREF="../../../../index.html?com/google/gson//class-useTypeAdapter.html" target="_top"><B>FRAMES</B></A> &nbsp;
222 &nbsp;<A HREF="TypeAdapter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
223 &nbsp;<SCRIPT type="text/javascript">
224 <!--
225 if(window==top) {
226 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
227 }
228 //-->
229 </SCRIPT>
230 <NOSCRIPT>
231 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
232 </NOSCRIPT>
233
234
235 </FONT></TD>
236 </TR>
237 </TABLE>
238 <A NAME="skip-navbar_bottom"></A>
239 <!-- ======== END OF BOTTOM NAVBAR ======= -->
240
241 <HR>
242 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
243 </BODY>
244 </HTML>
+0
-198
gson/docs/javadocs/com/google/gson/class-use/TypeAdapterFactory.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Interface com.google.gson.TypeAdapterFactory (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Interface com.google.gson.TypeAdapterFactory (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson//class-useTypeAdapterFactory.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="TypeAdapterFactory.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Interface<br>com.google.gson.TypeAdapterFactory</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A> in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>
117 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
118 <TR ALIGN="right" VALIGN="">
119 <TD NOWRAP><FONT SIZE="-1">
120 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
121 </TR>
122 </TABLE>
123 </CODE></FONT></TD>
124 <TD><CODE><B>Gson.</B><B><A HREF="../../../../com/google/gson/Gson.html#getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)">getDelegateAdapter</A></B>(<A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;skipPast,
125 <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method is used to get an alternate type adapter for the specified type.</TD>
129 </TR>
130 <TR BGCOLOR="white" CLASS="TableRowColor">
131 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
132 <CODE>&nbsp;<A HREF="../../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></CODE></FONT></TD>
133 <TD><CODE><B>GsonBuilder.</B><B><A HREF="../../../../com/google/gson/GsonBuilder.html#registerTypeAdapterFactory(com.google.gson.TypeAdapterFactory)">registerTypeAdapterFactory</A></B>(<A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;factory)</CODE>
134
135 <BR>
136 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Register a factory for type adapters.</TD>
137 </TR>
138 </TABLE>
139 &nbsp;
140 <P>
141 <HR>
142
143
144 <!-- ======= START OF BOTTOM NAVBAR ====== -->
145 <A NAME="navbar_bottom"><!-- --></A>
146 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
147 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
148 <TR>
149 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
150 <A NAME="navbar_bottom_firstrow"><!-- --></A>
151 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
152 <TR ALIGN="center" VALIGN="top">
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
155 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
156 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
157 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
158 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
159 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
160 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
161 </TR>
162 </TABLE>
163 </TD>
164 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
165 </EM>
166 </TD>
167 </TR>
168
169 <TR>
170 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
171 &nbsp;PREV&nbsp;
172 &nbsp;NEXT</FONT></TD>
173 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
174 <A HREF="../../../../index.html?com/google/gson//class-useTypeAdapterFactory.html" target="_top"><B>FRAMES</B></A> &nbsp;
175 &nbsp;<A HREF="TypeAdapterFactory.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
176 &nbsp;<SCRIPT type="text/javascript">
177 <!--
178 if(window==top) {
179 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
180 }
181 //-->
182 </SCRIPT>
183 <NOSCRIPT>
184 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
185 </NOSCRIPT>
186
187
188 </FONT></TD>
189 </TR>
190 </TABLE>
191 <A NAME="skip-navbar_bottom"></A>
192 <!-- ======== END OF BOTTOM NAVBAR ======= -->
193
194 <HR>
195 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
196 </BODY>
197 </HTML>
+0
-106
gson/docs/javadocs/com/google/gson/package-frame.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18 <FONT size="+1" CLASS="FrameTitleFont">
19 <A HREF="../../../com/google/gson/package-summary.html" target="classFrame">com.google.gson</A></FONT>
20 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
21 <TR>
22 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
23 Interfaces</FONT>&nbsp;
24 <FONT CLASS="FrameItemFont">
25 <BR>
26 <A HREF="ExclusionStrategy.html" title="interface in com.google.gson" target="classFrame"><I>ExclusionStrategy</I></A>
27 <BR>
28 <A HREF="FieldNamingStrategy.html" title="interface in com.google.gson" target="classFrame"><I>FieldNamingStrategy</I></A>
29 <BR>
30 <A HREF="InstanceCreator.html" title="interface in com.google.gson" target="classFrame"><I>InstanceCreator</I></A>
31 <BR>
32 <A HREF="JsonDeserializationContext.html" title="interface in com.google.gson" target="classFrame"><I>JsonDeserializationContext</I></A>
33 <BR>
34 <A HREF="JsonDeserializer.html" title="interface in com.google.gson" target="classFrame"><I>JsonDeserializer</I></A>
35 <BR>
36 <A HREF="JsonSerializationContext.html" title="interface in com.google.gson" target="classFrame"><I>JsonSerializationContext</I></A>
37 <BR>
38 <A HREF="JsonSerializer.html" title="interface in com.google.gson" target="classFrame"><I>JsonSerializer</I></A>
39 <BR>
40 <A HREF="TypeAdapterFactory.html" title="interface in com.google.gson" target="classFrame"><I>TypeAdapterFactory</I></A></FONT></TD>
41 </TR>
42 </TABLE>
43
44
45 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
46 <TR>
47 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
48 Classes</FONT>&nbsp;
49 <FONT CLASS="FrameItemFont">
50 <BR>
51 <A HREF="FieldAttributes.html" title="class in com.google.gson" target="classFrame">FieldAttributes</A>
52 <BR>
53 <A HREF="Gson.html" title="class in com.google.gson" target="classFrame">Gson</A>
54 <BR>
55 <A HREF="GsonBuilder.html" title="class in com.google.gson" target="classFrame">GsonBuilder</A>
56 <BR>
57 <A HREF="JsonArray.html" title="class in com.google.gson" target="classFrame">JsonArray</A>
58 <BR>
59 <A HREF="JsonElement.html" title="class in com.google.gson" target="classFrame">JsonElement</A>
60 <BR>
61 <A HREF="JsonNull.html" title="class in com.google.gson" target="classFrame">JsonNull</A>
62 <BR>
63 <A HREF="JsonObject.html" title="class in com.google.gson" target="classFrame">JsonObject</A>
64 <BR>
65 <A HREF="JsonParser.html" title="class in com.google.gson" target="classFrame">JsonParser</A>
66 <BR>
67 <A HREF="JsonPrimitive.html" title="class in com.google.gson" target="classFrame">JsonPrimitive</A>
68 <BR>
69 <A HREF="JsonStreamParser.html" title="class in com.google.gson" target="classFrame">JsonStreamParser</A>
70 <BR>
71 <A HREF="TypeAdapter.html" title="class in com.google.gson" target="classFrame">TypeAdapter</A></FONT></TD>
72 </TR>
73 </TABLE>
74
75
76 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
77 <TR>
78 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
79 Enums</FONT>&nbsp;
80 <FONT CLASS="FrameItemFont">
81 <BR>
82 <A HREF="FieldNamingPolicy.html" title="enum in com.google.gson" target="classFrame">FieldNamingPolicy</A>
83 <BR>
84 <A HREF="LongSerializationPolicy.html" title="enum in com.google.gson" target="classFrame">LongSerializationPolicy</A></FONT></TD>
85 </TR>
86 </TABLE>
87
88
89 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
90 <TR>
91 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
92 Exceptions</FONT>&nbsp;
93 <FONT CLASS="FrameItemFont">
94 <BR>
95 <A HREF="JsonIOException.html" title="class in com.google.gson" target="classFrame">JsonIOException</A>
96 <BR>
97 <A HREF="JsonParseException.html" title="class in com.google.gson" target="classFrame">JsonParseException</A>
98 <BR>
99 <A HREF="JsonSyntaxException.html" title="class in com.google.gson" target="classFrame">JsonSyntaxException</A></FONT></TD>
100 </TR>
101 </TABLE>
102
103
104 </BODY>
105 </HTML>
+0
-313
gson/docs/javadocs/com/google/gson/package-summary.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV PACKAGE&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/annotations/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <H2>
83 Package com.google.gson
84 </H2>
85 This package provides the <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
86 vice-versa.
87 <P>
88 <B>See:</B>
89 <BR>
90 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF="#package_description"><B>Description</B></A>
91 <P>
92
93 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
94 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
95 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
96 <B>Interface Summary</B></FONT></TH>
97 </TR>
98 <TR BGCOLOR="white" CLASS="TableRowColor">
99 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A></B></TD>
100 <TD>A strategy (or policy) definition that is used to decide whether or not a field or top-level
101 class should be serialized or deserialized as part of the JSON output/input.</TD>
102 </TR>
103 <TR BGCOLOR="white" CLASS="TableRowColor">
104 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A></B></TD>
105 <TD>A mechanism for providing custom field naming in Gson.</TD>
106 </TR>
107 <TR BGCOLOR="white" CLASS="TableRowColor">
108 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson">InstanceCreator&lt;T&gt;</A></B></TD>
109 <TD>This interface is implemented to create instances of a class that does not define a no-args
110 constructor.</TD>
111 </TR>
112 <TR BGCOLOR="white" CLASS="TableRowColor">
113 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A></B></TD>
114 <TD>Context for deserialization that is passed to a custom deserializer during invocation of its
115 <A HREF="../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><CODE>JsonDeserializer.deserialize(JsonElement, Type, JsonDeserializationContext)</CODE></A>
116 method.</TD>
117 </TR>
118 <TR BGCOLOR="white" CLASS="TableRowColor">
119 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson">JsonDeserializer&lt;T&gt;</A></B></TD>
120 <TD>Interface representing a custom deserializer for Json.</TD>
121 </TR>
122 <TR BGCOLOR="white" CLASS="TableRowColor">
123 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A></B></TD>
124 <TD>Context for serialization that is passed to a custom serializer during invocation of its
125 <A HREF="../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><CODE>JsonSerializer.serialize(Object, Type, JsonSerializationContext)</CODE></A> method.</TD>
126 </TR>
127 <TR BGCOLOR="white" CLASS="TableRowColor">
128 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson">JsonSerializer&lt;T&gt;</A></B></TD>
129 <TD>Interface representing a custom serializer for Json.</TD>
130 </TR>
131 <TR BGCOLOR="white" CLASS="TableRowColor">
132 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A></B></TD>
133 <TD>Creates type adapters for set of related types.</TD>
134 </TR>
135 </TABLE>
136 &nbsp;
137
138 <P>
139
140 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
141 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
142 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
143 <B>Class Summary</B></FONT></TH>
144 </TR>
145 <TR BGCOLOR="white" CLASS="TableRowColor">
146 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A></B></TD>
147 <TD>A data object that stores attributes of a field.</TD>
148 </TR>
149 <TR BGCOLOR="white" CLASS="TableRowColor">
150 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A></B></TD>
151 <TD>This is the main class for using Gson.</TD>
152 </TR>
153 <TR BGCOLOR="white" CLASS="TableRowColor">
154 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A></B></TD>
155 <TD>Use this builder to construct a <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance when you need to set configuration
156 options other than the default.</TD>
157 </TR>
158 <TR BGCOLOR="white" CLASS="TableRowColor">
159 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A></B></TD>
160 <TD>A class representing an array type in Json.</TD>
161 </TR>
162 <TR BGCOLOR="white" CLASS="TableRowColor">
163 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></B></TD>
164 <TD>A class representing an element of Json.</TD>
165 </TR>
166 <TR BGCOLOR="white" CLASS="TableRowColor">
167 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A></B></TD>
168 <TD>A class representing a Json <code>null</code> value.</TD>
169 </TR>
170 <TR BGCOLOR="white" CLASS="TableRowColor">
171 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A></B></TD>
172 <TD>A class representing an object type in Json.</TD>
173 </TR>
174 <TR BGCOLOR="white" CLASS="TableRowColor">
175 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonParser.html" title="class in com.google.gson">JsonParser</A></B></TD>
176 <TD>A parser to parse Json into a parse tree of <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s</TD>
177 </TR>
178 <TR BGCOLOR="white" CLASS="TableRowColor">
179 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A></B></TD>
180 <TD>A class representing a Json primitive value.</TD>
181 </TR>
182 <TR BGCOLOR="white" CLASS="TableRowColor">
183 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A></B></TD>
184 <TD>A streaming parser that allows reading of multiple <A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s from the specified reader
185 asynchronously.</TD>
186 </TR>
187 <TR BGCOLOR="white" CLASS="TableRowColor">
188 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter&lt;T&gt;</A></B></TD>
189 <TD>Converts Java objects to and from JSON.</TD>
190 </TR>
191 </TABLE>
192 &nbsp;
193
194 <P>
195
196 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
197 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
198 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
199 <B>Enum Summary</B></FONT></TH>
200 </TR>
201 <TR BGCOLOR="white" CLASS="TableRowColor">
202 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A></B></TD>
203 <TD>An enumeration that defines a few standard naming conventions for JSON field names.</TD>
204 </TR>
205 <TR BGCOLOR="white" CLASS="TableRowColor">
206 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A></B></TD>
207 <TD>Defines the expected format for a <code>long</code> or <code>Long</code> type when its serialized.</TD>
208 </TR>
209 </TABLE>
210 &nbsp;
211
212 <P>
213
214 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
215 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
216 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
217 <B>Exception Summary</B></FONT></TH>
218 </TR>
219 <TR BGCOLOR="white" CLASS="TableRowColor">
220 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A></B></TD>
221 <TD>This exception is raised when Gson was unable to read an input stream
222 or write to one.</TD>
223 </TR>
224 <TR BGCOLOR="white" CLASS="TableRowColor">
225 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A></B></TD>
226 <TD>This exception is raised if there is a serious issue that occurs during parsing of a Json
227 string.</TD>
228 </TR>
229 <TR BGCOLOR="white" CLASS="TableRowColor">
230 <TD WIDTH="15%"><B><A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A></B></TD>
231 <TD>This exception is raised when Gson attempts to read (or write) a malformed
232 JSON element.</TD>
233 </TR>
234 </TABLE>
235 &nbsp;
236
237 <P>
238 <A NAME="package_description"><!-- --></A><H2>
239 Package com.google.gson Description
240 </H2>
241
242 <P>
243 This package provides the <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
244 vice-versa.
245
246 <p>The primary class to use is <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> which can be constructed with
247 <code>new Gson()</code> (using default settings) or by using <A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><CODE>GsonBuilder</CODE></A>
248 (to configure various options such as using versioning and so on).</p>
249 <P>
250
251 <P>
252 <DL>
253 <DT><B>Author:</B></DT>
254 <DD>Inderjeet Singh, Joel Leitch</DD>
255 </DL>
256 <HR>
257
258
259 <!-- ======= START OF BOTTOM NAVBAR ====== -->
260 <A NAME="navbar_bottom"><!-- --></A>
261 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
262 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
263 <TR>
264 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
265 <A NAME="navbar_bottom_firstrow"><!-- --></A>
266 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
267 <TR ALIGN="center" VALIGN="top">
268 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
269 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
270 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
271 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
272 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
273 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
274 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
275 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
276 </TR>
277 </TABLE>
278 </TD>
279 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
280 </EM>
281 </TD>
282 </TR>
283
284 <TR>
285 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
286 &nbsp;PREV PACKAGE&nbsp;
287 &nbsp;<A HREF="../../../com/google/gson/annotations/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
288 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
289 <A HREF="../../../index.html?com/google/gson/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
290 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
291 &nbsp;<SCRIPT type="text/javascript">
292 <!--
293 if(window==top) {
294 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
295 }
296 //-->
297 </SCRIPT>
298 <NOSCRIPT>
299 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
300 </NOSCRIPT>
301
302
303 </FONT></TD>
304 </TR>
305 </TABLE>
306 <A NAME="skip-navbar_bottom"></A>
307 <!-- ======== END OF BOTTOM NAVBAR ======= -->
308
309 <HR>
310 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
311 </BODY>
312 </HTML>
+0
-183
gson/docs/javadocs/com/google/gson/package-tree.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson Class Hierarchy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson Class Hierarchy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;<A HREF="../../../com/google/gson/annotations/package-tree.html"><B>NEXT</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 Hierarchy For Package com.google.gson
85 </H2>
86 </CENTER>
87 <DL>
88 <DT><B>Package Hierarchies:</B><DD><A HREF="../../../overview-tree.html">All Packages</A></DL>
89 <HR>
90 <H2>
91 Class Hierarchy
92 </H2>
93 <UL>
94 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
95 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>FieldAttributes</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><B>Gson</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>GsonBuilder</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonElement.html" title="class in com.google.gson"><B>JsonElement</B></A><UL>
96 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonArray.html" title="class in com.google.gson"><B>JsonArray</B></A> (implements java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;T&gt;)
97 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonNull.html" title="class in com.google.gson"><B>JsonNull</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonObject.html" title="class in com.google.gson"><B>JsonObject</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>JsonPrimitive</B></A></UL>
98 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonParser.html" title="class in com.google.gson"><B>JsonParser</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>JsonStreamParser</B></A> (implements java.util.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;E&gt;)
99 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang"><B>Throwable</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>)
100 <UL>
101 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang"><B>Exception</B></A><UL>
102 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang"><B>RuntimeException</B></A><UL>
103 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>JsonParseException</B></A><UL>
104 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>JsonIOException</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>JsonSyntaxException</B></A></UL>
105 </UL>
106 </UL>
107 </UL>
108 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>TypeAdapter</B></A>&lt;T&gt;</UL>
109 </UL>
110 <H2>
111 Interface Hierarchy
112 </H2>
113 <UL>
114 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><B>ExclusionStrategy</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>FieldNamingStrategy</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>InstanceCreator</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>JsonDeserializationContext</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>JsonDeserializer</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>JsonSerializationContext</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>JsonSerializer</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><B>TypeAdapterFactory</B></A></UL>
115 <H2>
116 Enum Hierarchy
117 </H2>
118 <UL>
119 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
120 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang"><B>Enum</B></A>&lt;E&gt; (implements java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;T&gt;, java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>)
121 <UL>
122 <LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>LongSerializationPolicy</B></A><LI TYPE="circle">com.google.gson.<A HREF="../../../com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>FieldNamingPolicy</B></A> (implements com.google.gson.<A HREF="../../../com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>)
123 </UL>
124 </UL>
125 </UL>
126 <HR>
127
128
129 <!-- ======= START OF BOTTOM NAVBAR ====== -->
130 <A NAME="navbar_bottom"><!-- --></A>
131 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
132 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
133 <TR>
134 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
135 <A NAME="navbar_bottom_firstrow"><!-- --></A>
136 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
137 <TR ALIGN="center" VALIGN="top">
138 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
139 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
140 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
141 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
142 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
143 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
144 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
145 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
146 </TR>
147 </TABLE>
148 </TD>
149 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
150 </EM>
151 </TD>
152 </TR>
153
154 <TR>
155 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
156 &nbsp;PREV&nbsp;
157 &nbsp;<A HREF="../../../com/google/gson/annotations/package-tree.html"><B>NEXT</B></A></FONT></TD>
158 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
159 <A HREF="../../../index.html?com/google/gson/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
160 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
161 &nbsp;<SCRIPT type="text/javascript">
162 <!--
163 if(window==top) {
164 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
165 }
166 //-->
167 </SCRIPT>
168 <NOSCRIPT>
169 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
170 </NOSCRIPT>
171
172
173 </FONT></TD>
174 </TR>
175 </TABLE>
176 <A NAME="skip-navbar_bottom"></A>
177 <!-- ======== END OF BOTTOM NAVBAR ======= -->
178
179 <HR>
180 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
181 </BODY>
182 </HTML>
+0
-288
gson/docs/javadocs/com/google/gson/package-use.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Package com.google.gson (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Package com.google.gson (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../index.html?com/google/gson/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Package<br>com.google.gson</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Classes in <A HREF="../../../com/google/gson/package-summary.html">com.google.gson</A> used by <A HREF="../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 <TR BGCOLOR="white" CLASS="TableRowColor">
107 <TD><B><A HREF="../../../com/google/gson/class-use/ExclusionStrategy.html#com.google.gson"><B>ExclusionStrategy</B></A></B>
108
109 <BR>
110 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A strategy (or policy) definition that is used to decide whether or not a field or top-level
111 class should be serialized or deserialized as part of the JSON output/input.</TD>
112 </TR>
113 <TR BGCOLOR="white" CLASS="TableRowColor">
114 <TD><B><A HREF="../../../com/google/gson/class-use/FieldAttributes.html#com.google.gson"><B>FieldAttributes</B></A></B>
115
116 <BR>
117 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A data object that stores attributes of a field.</TD>
118 </TR>
119 <TR BGCOLOR="white" CLASS="TableRowColor">
120 <TD><B><A HREF="../../../com/google/gson/class-use/FieldNamingPolicy.html#com.google.gson"><B>FieldNamingPolicy</B></A></B>
121
122 <BR>
123 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An enumeration that defines a few standard naming conventions for JSON field names.</TD>
124 </TR>
125 <TR BGCOLOR="white" CLASS="TableRowColor">
126 <TD><B><A HREF="../../../com/google/gson/class-use/FieldNamingStrategy.html#com.google.gson"><B>FieldNamingStrategy</B></A></B>
127
128 <BR>
129 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A mechanism for providing custom field naming in Gson.</TD>
130 </TR>
131 <TR BGCOLOR="white" CLASS="TableRowColor">
132 <TD><B><A HREF="../../../com/google/gson/class-use/Gson.html#com.google.gson"><B>Gson</B></A></B>
133
134 <BR>
135 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This is the main class for using Gson.</TD>
136 </TR>
137 <TR BGCOLOR="white" CLASS="TableRowColor">
138 <TD><B><A HREF="../../../com/google/gson/class-use/GsonBuilder.html#com.google.gson"><B>GsonBuilder</B></A></B>
139
140 <BR>
141 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Use this builder to construct a <A HREF="../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance when you need to set configuration
142 options other than the default.</TD>
143 </TR>
144 <TR BGCOLOR="white" CLASS="TableRowColor">
145 <TD><B><A HREF="../../../com/google/gson/class-use/JsonArray.html#com.google.gson"><B>JsonArray</B></A></B>
146
147 <BR>
148 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing an array type in Json.</TD>
149 </TR>
150 <TR BGCOLOR="white" CLASS="TableRowColor">
151 <TD><B><A HREF="../../../com/google/gson/class-use/JsonDeserializationContext.html#com.google.gson"><B>JsonDeserializationContext</B></A></B>
152
153 <BR>
154 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Context for deserialization that is passed to a custom deserializer during invocation of its
155 <A HREF="../../../com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><CODE>JsonDeserializer.deserialize(JsonElement, Type, JsonDeserializationContext)</CODE></A>
156 method.</TD>
157 </TR>
158 <TR BGCOLOR="white" CLASS="TableRowColor">
159 <TD><B><A HREF="../../../com/google/gson/class-use/JsonElement.html#com.google.gson"><B>JsonElement</B></A></B>
160
161 <BR>
162 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing an element of Json.</TD>
163 </TR>
164 <TR BGCOLOR="white" CLASS="TableRowColor">
165 <TD><B><A HREF="../../../com/google/gson/class-use/JsonIOException.html#com.google.gson"><B>JsonIOException</B></A></B>
166
167 <BR>
168 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This exception is raised when Gson was unable to read an input stream
169 or write to one.</TD>
170 </TR>
171 <TR BGCOLOR="white" CLASS="TableRowColor">
172 <TD><B><A HREF="../../../com/google/gson/class-use/JsonNull.html#com.google.gson"><B>JsonNull</B></A></B>
173
174 <BR>
175 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing a Json <code>null</code> value.</TD>
176 </TR>
177 <TR BGCOLOR="white" CLASS="TableRowColor">
178 <TD><B><A HREF="../../../com/google/gson/class-use/JsonObject.html#com.google.gson"><B>JsonObject</B></A></B>
179
180 <BR>
181 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing an object type in Json.</TD>
182 </TR>
183 <TR BGCOLOR="white" CLASS="TableRowColor">
184 <TD><B><A HREF="../../../com/google/gson/class-use/JsonParseException.html#com.google.gson"><B>JsonParseException</B></A></B>
185
186 <BR>
187 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This exception is raised if there is a serious issue that occurs during parsing of a Json
188 string.</TD>
189 </TR>
190 <TR BGCOLOR="white" CLASS="TableRowColor">
191 <TD><B><A HREF="../../../com/google/gson/class-use/JsonPrimitive.html#com.google.gson"><B>JsonPrimitive</B></A></B>
192
193 <BR>
194 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A class representing a Json primitive value.</TD>
195 </TR>
196 <TR BGCOLOR="white" CLASS="TableRowColor">
197 <TD><B><A HREF="../../../com/google/gson/class-use/JsonSerializationContext.html#com.google.gson"><B>JsonSerializationContext</B></A></B>
198
199 <BR>
200 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Context for serialization that is passed to a custom serializer during invocation of its
201 <A HREF="../../../com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><CODE>JsonSerializer.serialize(Object, Type, JsonSerializationContext)</CODE></A> method.</TD>
202 </TR>
203 <TR BGCOLOR="white" CLASS="TableRowColor">
204 <TD><B><A HREF="../../../com/google/gson/class-use/JsonSyntaxException.html#com.google.gson"><B>JsonSyntaxException</B></A></B>
205
206 <BR>
207 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This exception is raised when Gson attempts to read (or write) a malformed
208 JSON element.</TD>
209 </TR>
210 <TR BGCOLOR="white" CLASS="TableRowColor">
211 <TD><B><A HREF="../../../com/google/gson/class-use/LongSerializationPolicy.html#com.google.gson"><B>LongSerializationPolicy</B></A></B>
212
213 <BR>
214 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Defines the expected format for a <code>long</code> or <code>Long</code> type when its serialized.</TD>
215 </TR>
216 <TR BGCOLOR="white" CLASS="TableRowColor">
217 <TD><B><A HREF="../../../com/google/gson/class-use/TypeAdapter.html#com.google.gson"><B>TypeAdapter</B></A></B>
218
219 <BR>
220 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Converts Java objects to and from JSON.</TD>
221 </TR>
222 <TR BGCOLOR="white" CLASS="TableRowColor">
223 <TD><B><A HREF="../../../com/google/gson/class-use/TypeAdapterFactory.html#com.google.gson"><B>TypeAdapterFactory</B></A></B>
224
225 <BR>
226 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates type adapters for set of related types.</TD>
227 </TR>
228 </TABLE>
229 &nbsp;
230 <P>
231 <HR>
232
233
234 <!-- ======= START OF BOTTOM NAVBAR ====== -->
235 <A NAME="navbar_bottom"><!-- --></A>
236 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
237 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
238 <TR>
239 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
240 <A NAME="navbar_bottom_firstrow"><!-- --></A>
241 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
242 <TR ALIGN="center" VALIGN="top">
243 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
244 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
245 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
246 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
247 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
248 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
249 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
250 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
251 </TR>
252 </TABLE>
253 </TD>
254 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
255 </EM>
256 </TD>
257 </TR>
258
259 <TR>
260 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
261 &nbsp;PREV&nbsp;
262 &nbsp;NEXT</FONT></TD>
263 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
264 <A HREF="../../../index.html?com/google/gson/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
265 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
266 &nbsp;<SCRIPT type="text/javascript">
267 <!--
268 if(window==top) {
269 document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
270 }
271 //-->
272 </SCRIPT>
273 <NOSCRIPT>
274 <A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
275 </NOSCRIPT>
276
277
278 </FONT></TD>
279 </TR>
280 </TABLE>
281 <A NAME="skip-navbar_bottom"></A>
282 <!-- ======== END OF BOTTOM NAVBAR ======= -->
283
284 <HR>
285 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
286 </BODY>
287 </HTML>
+0
-498
gson/docs/javadocs/com/google/gson/reflect/TypeToken.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 TypeToken (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="TypeToken (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/TypeToken.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV CLASS&nbsp;
59 &nbsp;NEXT CLASS</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/reflect/TypeToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="TypeToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.reflect</FONT>
92 <BR>
93 Class TypeToken&lt;T&gt;</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.reflect.TypeToken&lt;T&gt;</B>
97 </PRE>
98 <HR>
99 <DL>
100 <DT><PRE>public class <B>TypeToken&lt;T&gt;</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101 </PRE>
102
103 <P>
104 Represents a generic type <code>T</code>. Java doesn't yet provide a way to
105 represent generic types, so this class does. Forces clients to create a
106 subclass of this class which enables retrieval the type information even at
107 runtime.
108
109 <p>For example, to create a type literal for <code>List&lt;String&gt;</code>, you can
110 create an empty anonymous inner class:
111
112 <p>
113 <code>TypeToken&lt;List&lt;String&gt;&gt; list = new TypeToken&lt;List&lt;String&gt;&gt;() {};</code>
114
115 <p>This syntax cannot be used to create type literals that have wildcard
116 parameters, such as <code>Class&lt;?&gt;</code> or <code>List&lt;? extends CharSequence&gt;</code>.
117 <P>
118
119 <P>
120 <DL>
121 <DT><B>Author:</B></DT>
122 <DD>Bob Lee, Sven Mawson, Jesse Wilson</DD>
123 </DL>
124 <HR>
125
126 <P>
127
128 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
129
130 <A NAME="constructor_summary"><!-- --></A>
131 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
132 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
133 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
134 <B>Constructor Summary</B></FONT></TH>
135 </TR>
136 <TR BGCOLOR="white" CLASS="TableRowColor">
137 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
138 <CODE>protected </CODE></FONT></TD>
139 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#TypeToken()">TypeToken</A></B>()</CODE>
140
141 <BR>
142 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a new type literal.</TD>
143 </TR>
144 </TABLE>
145 &nbsp;
146 <!-- ========== METHOD SUMMARY =========== -->
147
148 <A NAME="method_summary"><!-- --></A>
149 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
150 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
151 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
152 <B>Method Summary</B></FONT></TH>
153 </TR>
154 <TR BGCOLOR="white" CLASS="TableRowColor">
155 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
156 <CODE>&nbsp;boolean</CODE></FONT></TD>
157 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#equals(java.lang.Object)">equals</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;o)</CODE>
158
159 <BR>
160 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
161 </TR>
162 <TR BGCOLOR="white" CLASS="TableRowColor">
163 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
164 <CODE>static
165 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
166 <TR ALIGN="right" VALIGN="">
167 <TD NOWRAP><FONT SIZE="-1">
168 <CODE>&lt;T&gt; <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;</CODE></FONT></TD>
169 </TR>
170 </TABLE>
171 </CODE></FONT></TD>
172 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#get(java.lang.Class)">get</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;type)</CODE>
173
174 <BR>
175 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets type literal for the given <code>Class</code> instance.</TD>
176 </TR>
177 <TR BGCOLOR="white" CLASS="TableRowColor">
178 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
179 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;?&gt;</CODE></FONT></TD>
180 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#get(java.lang.reflect.Type)">get</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type)</CODE>
181
182 <BR>
183 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets type literal for the given <code>Type</code> instance.</TD>
184 </TR>
185 <TR BGCOLOR="white" CLASS="TableRowColor">
186 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
187 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;? super <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="type parameter in TypeToken">T</A>&gt;</CODE></FONT></TD>
188 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#getRawType()">getRawType</A></B>()</CODE>
189
190 <BR>
191 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the raw (non-generic) type for this type.</TD>
192 </TR>
193 <TR BGCOLOR="white" CLASS="TableRowColor">
194 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
195 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A></CODE></FONT></TD>
196 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#getType()">getType</A></B>()</CODE>
197
198 <BR>
199 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets underlying <code>Type</code> instance.</TD>
200 </TR>
201 <TR BGCOLOR="white" CLASS="TableRowColor">
202 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
203 <CODE>&nbsp;int</CODE></FONT></TD>
204 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#hashCode()">hashCode</A></B>()</CODE>
205
206 <BR>
207 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
208 </TR>
209 <TR BGCOLOR="white" CLASS="TableRowColor">
210 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
211 <CODE>&nbsp;boolean</CODE></FONT></TD>
212 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#isAssignableFrom(java.lang.Class)">isAssignableFrom</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;cls)</CODE>
213
214 <BR>
215 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
216 with wildcards.</I></TD>
217 </TR>
218 <TR BGCOLOR="white" CLASS="TableRowColor">
219 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
220 <CODE>&nbsp;boolean</CODE></FONT></TD>
221 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#isAssignableFrom(java.lang.reflect.Type)">isAssignableFrom</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;from)</CODE>
222
223 <BR>
224 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
225 with wildcards.</I></TD>
226 </TR>
227 <TR BGCOLOR="white" CLASS="TableRowColor">
228 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
229 <CODE>&nbsp;boolean</CODE></FONT></TD>
230 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#isAssignableFrom(com.google.gson.reflect.TypeToken)">isAssignableFrom</A></B>(<A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;?&gt;&nbsp;token)</CODE>
231
232 <BR>
233 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
234 with wildcards.</I></TD>
235 </TR>
236 <TR BGCOLOR="white" CLASS="TableRowColor">
237 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
238 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
239 <TD><CODE><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html#toString()">toString</A></B>()</CODE>
240
241 <BR>
242 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
243 </TR>
244 </TABLE>
245 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
246 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
247 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
248 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
249 </TR>
250 <TR BGCOLOR="white" CLASS="TableRowColor">
251 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
252 </TR>
253 </TABLE>
254 &nbsp;
255 <P>
256
257 <!-- ========= CONSTRUCTOR DETAIL ======== -->
258
259 <A NAME="constructor_detail"><!-- --></A>
260 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
261 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
262 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
263 <B>Constructor Detail</B></FONT></TH>
264 </TR>
265 </TABLE>
266
267 <A NAME="TypeToken()"><!-- --></A><H3>
268 TypeToken</H3>
269 <PRE>
270 protected <B>TypeToken</B>()</PRE>
271 <DL>
272 <DD>Constructs a new type literal. Derives represented class from type
273 parameter.
274
275 <p>Clients create an empty anonymous subclass. Doing so embeds the type
276 parameter in the anonymous class's type hierarchy so we can reconstitute it
277 at runtime despite erasure.
278 <P>
279 </DL>
280
281 <!-- ============ METHOD DETAIL ========== -->
282
283 <A NAME="method_detail"><!-- --></A>
284 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
285 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
286 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
287 <B>Method Detail</B></FONT></TH>
288 </TR>
289 </TABLE>
290
291 <A NAME="getRawType()"><!-- --></A><H3>
292 getRawType</H3>
293 <PRE>
294 public final <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;? super <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="type parameter in TypeToken">T</A>&gt; <B>getRawType</B>()</PRE>
295 <DL>
296 <DD>Returns the raw (non-generic) type for this type.
297 <P>
298 <DD><DL>
299 </DL>
300 </DD>
301 </DL>
302 <HR>
303
304 <A NAME="getType()"><!-- --></A><H3>
305 getType</H3>
306 <PRE>
307 public final <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A> <B>getType</B>()</PRE>
308 <DL>
309 <DD>Gets underlying <code>Type</code> instance.
310 <P>
311 <DD><DL>
312 </DL>
313 </DD>
314 </DL>
315 <HR>
316
317 <A NAME="isAssignableFrom(java.lang.Class)"><!-- --></A><H3>
318 isAssignableFrom</H3>
319 <PRE>
320 <FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</A>
321 </FONT>public boolean <B>isAssignableFrom</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;?&gt;&nbsp;cls)</PRE>
322 <DL>
323 <DD><B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
324 with wildcards.</I>
325 <P>
326 <DD>Check if this type is assignable from the given class object.
327 <P>
328 <DD><DL>
329 </DL>
330 </DD>
331 </DL>
332 <HR>
333
334 <A NAME="isAssignableFrom(java.lang.reflect.Type)"><!-- --></A><H3>
335 isAssignableFrom</H3>
336 <PRE>
337 <FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</A>
338 </FONT>public boolean <B>isAssignableFrom</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;from)</PRE>
339 <DL>
340 <DD><B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
341 with wildcards.</I>
342 <P>
343 <DD>Check if this type is assignable from the given Type.
344 <P>
345 <DD><DL>
346 </DL>
347 </DD>
348 </DL>
349 <HR>
350
351 <A NAME="isAssignableFrom(com.google.gson.reflect.TypeToken)"><!-- --></A><H3>
352 isAssignableFrom</H3>
353 <PRE>
354 <FONT SIZE="-1"><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</A>
355 </FONT>public boolean <B>isAssignableFrom</B>(<A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;?&gt;&nbsp;token)</PRE>
356 <DL>
357 <DD><B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
358 with wildcards.</I>
359 <P>
360 <DD>Check if this type is assignable from the given type token.
361 <P>
362 <DD><DL>
363 </DL>
364 </DD>
365 </DL>
366 <HR>
367
368 <A NAME="hashCode()"><!-- --></A><H3>
369 hashCode</H3>
370 <PRE>
371 public final int <B>hashCode</B>()</PRE>
372 <DL>
373 <DD><DL>
374 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
375 </DD>
376 <DD><DL>
377 </DL>
378 </DD>
379 </DL>
380 <HR>
381
382 <A NAME="equals(java.lang.Object)"><!-- --></A><H3>
383 equals</H3>
384 <PRE>
385 public final boolean <B>equals</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;o)</PRE>
386 <DL>
387 <DD><DL>
388 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
389 </DD>
390 <DD><DL>
391 </DL>
392 </DD>
393 </DL>
394 <HR>
395
396 <A NAME="toString()"><!-- --></A><H3>
397 toString</H3>
398 <PRE>
399 public final <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toString</B>()</PRE>
400 <DL>
401 <DD><DL>
402 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
403 </DD>
404 <DD><DL>
405 </DL>
406 </DD>
407 </DL>
408 <HR>
409
410 <A NAME="get(java.lang.reflect.Type)"><!-- --></A><H3>
411 get</H3>
412 <PRE>
413 public static <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;?&gt; <B>get</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type)</PRE>
414 <DL>
415 <DD>Gets type literal for the given <code>Type</code> instance.
416 <P>
417 <DD><DL>
418 </DL>
419 </DD>
420 </DL>
421 <HR>
422
423 <A NAME="get(java.lang.Class)"><!-- --></A><H3>
424 get</H3>
425 <PRE>
426 public static &lt;T&gt; <A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt; <B>get</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;type)</PRE>
427 <DL>
428 <DD>Gets type literal for the given <code>Class</code> instance.
429 <P>
430 <DD><DL>
431 </DL>
432 </DD>
433 </DL>
434 <!-- ========= END OF CLASS DATA ========= -->
435 <HR>
436
437
438 <!-- ======= START OF BOTTOM NAVBAR ====== -->
439 <A NAME="navbar_bottom"><!-- --></A>
440 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
441 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
442 <TR>
443 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
444 <A NAME="navbar_bottom_firstrow"><!-- --></A>
445 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
446 <TR ALIGN="center" VALIGN="top">
447 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
448 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
449 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
450 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/TypeToken.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
451 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
452 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
453 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
454 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
455 </TR>
456 </TABLE>
457 </TD>
458 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
459 </EM>
460 </TD>
461 </TR>
462
463 <TR>
464 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
465 &nbsp;PREV CLASS&nbsp;
466 &nbsp;NEXT CLASS</FONT></TD>
467 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
468 <A HREF="../../../../index.html?com/google/gson/reflect/TypeToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
469 &nbsp;<A HREF="TypeToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
470 &nbsp;<SCRIPT type="text/javascript">
471 <!--
472 if(window==top) {
473 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
474 }
475 //-->
476 </SCRIPT>
477 <NOSCRIPT>
478 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
479 </NOSCRIPT>
480
481
482 </FONT></TD>
483 </TR>
484 <TR>
485 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
486 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
487 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
488 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
489 </TR>
490 </TABLE>
491 <A NAME="skip-navbar_bottom"></A>
492 <!-- ======== END OF BOTTOM NAVBAR ======= -->
493
494 <HR>
495 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
496 </BODY>
497 </HTML>
+0
-283
gson/docs/javadocs/com/google/gson/reflect/class-use/TypeToken.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.reflect.TypeToken (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.reflect.TypeToken (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/reflect//class-useTypeToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="TypeToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.reflect.TypeToken</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 <TR BGCOLOR="white" CLASS="TableRowColor">
98 <TD><A HREF="#com.google.gson.reflect"><B>com.google.gson.reflect</B></A></TD>
99 <TD>This package provides utility classes for finding type information for generic types.&nbsp;</TD>
100 </TR>
101 </TABLE>
102 &nbsp;
103 <P>
104 <A NAME="com.google.gson"><!-- --></A>
105 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
106 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
107 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
108 Uses of <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A> in <A HREF="../../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
109 </TR>
110 </TABLE>
111 &nbsp;
112 <P>
113
114 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
115 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
116 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A></FONT></TH>
117 </TR>
118 <TR BGCOLOR="white" CLASS="TableRowColor">
119 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
120 <CODE>
121 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
122 <TR ALIGN="right" VALIGN="">
123 <TD NOWRAP><FONT SIZE="-1">
124 <CODE>&lt;T&gt; <A HREF="../../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
125 </TR>
126 </TABLE>
127 </CODE></FONT></TD>
128 <TD><CODE><B>TypeAdapterFactory.</B><B><A HREF="../../../../../com/google/gson/TypeAdapterFactory.html#create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)">create</A></B>(<A HREF="../../../../../com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>&nbsp;gson,
129 <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
130
131 <BR>
132 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a type adapter for <code>type</code>, or null if this factory doesn't
133 support <code>type</code>.</TD>
134 </TR>
135 <TR BGCOLOR="white" CLASS="TableRowColor">
136 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
137 <CODE>
138 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
139 <TR ALIGN="right" VALIGN="">
140 <TD NOWRAP><FONT SIZE="-1">
141 <CODE>&lt;T&gt; <A HREF="../../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
142 </TR>
143 </TABLE>
144 </CODE></FONT></TD>
145 <TD><CODE><B>Gson.</B><B><A HREF="../../../../../com/google/gson/Gson.html#getAdapter(com.google.gson.reflect.TypeToken)">getAdapter</A></B>(<A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
146
147 <BR>
148 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type adapter for <code></code> type.</TD>
149 </TR>
150 <TR BGCOLOR="white" CLASS="TableRowColor">
151 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
152 <CODE>
153 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
154 <TR ALIGN="right" VALIGN="">
155 <TD NOWRAP><FONT SIZE="-1">
156 <CODE>&lt;T&gt; <A HREF="../../../../../com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>&lt;T&gt;</CODE></FONT></TD>
157 </TR>
158 </TABLE>
159 </CODE></FONT></TD>
160 <TD><CODE><B>Gson.</B><B><A HREF="../../../../../com/google/gson/Gson.html#getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)">getDelegateAdapter</A></B>(<A HREF="../../../../../com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>&nbsp;skipPast,
161 <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;&nbsp;type)</CODE>
162
163 <BR>
164 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;This method is used to get an alternate type adapter for the specified type.</TD>
165 </TR>
166 </TABLE>
167 &nbsp;
168 <P>
169 <A NAME="com.google.gson.reflect"><!-- --></A>
170 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
171 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
172 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
173 Uses of <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A> in <A HREF="../../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A></FONT></TH>
174 </TR>
175 </TABLE>
176 &nbsp;
177 <P>
178
179 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
180 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
181 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A> that return <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A></FONT></TH>
182 </TR>
183 <TR BGCOLOR="white" CLASS="TableRowColor">
184 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
185 <CODE>static
186 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
187 <TR ALIGN="right" VALIGN="">
188 <TD NOWRAP><FONT SIZE="-1">
189 <CODE>&lt;T&gt; <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;T&gt;</CODE></FONT></TD>
190 </TR>
191 </TABLE>
192 </CODE></FONT></TD>
193 <TD><CODE><B>TypeToken.</B><B><A HREF="../../../../../com/google/gson/reflect/TypeToken.html#get(java.lang.Class)">get</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</A>&lt;T&gt;&nbsp;type)</CODE>
194
195 <BR>
196 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets type literal for the given <code>Class</code> instance.</TD>
197 </TR>
198 <TR BGCOLOR="white" CLASS="TableRowColor">
199 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
200 <CODE>static&nbsp;<A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;?&gt;</CODE></FONT></TD>
201 <TD><CODE><B>TypeToken.</B><B><A HREF="../../../../../com/google/gson/reflect/TypeToken.html#get(java.lang.reflect.Type)">get</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;type)</CODE>
202
203 <BR>
204 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets type literal for the given <code>Type</code> instance.</TD>
205 </TR>
206 </TABLE>
207 &nbsp;
208 <P>
209
210 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
211 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
212 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A> with parameters of type <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A></FONT></TH>
213 </TR>
214 <TR BGCOLOR="white" CLASS="TableRowColor">
215 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
216 <CODE>&nbsp;boolean</CODE></FONT></TD>
217 <TD><CODE><B>TypeToken.</B><B><A HREF="../../../../../com/google/gson/reflect/TypeToken.html#isAssignableFrom(com.google.gson.reflect.TypeToken)">isAssignableFrom</A></B>(<A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>&lt;?&gt;&nbsp;token)</CODE>
218
219 <BR>
220 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
221 with wildcards.</I></TD>
222 </TR>
223 </TABLE>
224 &nbsp;
225 <P>
226 <HR>
227
228
229 <!-- ======= START OF BOTTOM NAVBAR ====== -->
230 <A NAME="navbar_bottom"><!-- --></A>
231 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
232 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
233 <TR>
234 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
235 <A NAME="navbar_bottom_firstrow"><!-- --></A>
236 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
237 <TR ALIGN="center" VALIGN="top">
238 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
239 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
240 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
241 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
242 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
243 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
244 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
245 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
246 </TR>
247 </TABLE>
248 </TD>
249 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
250 </EM>
251 </TD>
252 </TR>
253
254 <TR>
255 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
256 &nbsp;PREV&nbsp;
257 &nbsp;NEXT</FONT></TD>
258 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
259 <A HREF="../../../../../index.html?com/google/gson/reflect//class-useTypeToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
260 &nbsp;<A HREF="TypeToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
261 &nbsp;<SCRIPT type="text/javascript">
262 <!--
263 if(window==top) {
264 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
265 }
266 //-->
267 </SCRIPT>
268 <NOSCRIPT>
269 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
270 </NOSCRIPT>
271
272
273 </FONT></TD>
274 </TR>
275 </TABLE>
276 <A NAME="skip-navbar_bottom"></A>
277 <!-- ======== END OF BOTTOM NAVBAR ======= -->
278
279 <HR>
280 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
281 </BODY>
282 </HTML>
+0
-33
gson/docs/javadocs/com/google/gson/reflect/package-frame.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.reflect (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18 <FONT size="+1" CLASS="FrameTitleFont">
19 <A HREF="../../../../com/google/gson/reflect/package-summary.html" target="classFrame">com.google.gson.reflect</A></FONT>
20 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
21 <TR>
22 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
23 Classes</FONT>&nbsp;
24 <FONT CLASS="FrameItemFont">
25 <BR>
26 <A HREF="TypeToken.html" title="class in com.google.gson.reflect" target="classFrame">TypeToken</A></FONT></TD>
27 </TR>
28 </TABLE>
29
30
31 </BODY>
32 </HTML>
+0
-175
gson/docs/javadocs/com/google/gson/reflect/package-summary.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.reflect (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson.reflect (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/annotations/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/stream/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/reflect/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <H2>
83 Package com.google.gson.reflect
84 </H2>
85 This package provides utility classes for finding type information for generic types.
86 <P>
87 <B>See:</B>
88 <BR>
89 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<A HREF="#package_description"><B>Description</B></A>
90 <P>
91
92 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
93 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
94 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
95 <B>Class Summary</B></FONT></TH>
96 </TR>
97 <TR BGCOLOR="white" CLASS="TableRowColor">
98 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken&lt;T&gt;</A></B></TD>
99 <TD>Represents a generic type <code>T</code>.</TD>
100 </TR>
101 </TABLE>
102 &nbsp;
103
104 <P>
105 <A NAME="package_description"><!-- --></A><H2>
106 Package com.google.gson.reflect Description
107 </H2>
108
109 <P>
110 This package provides utility classes for finding type information for generic types.
111 <P>
112
113 <P>
114 <DL>
115 <DT><B>Author:</B></DT>
116 <DD>Inderjeet Singh, Joel Leitch</DD>
117 </DL>
118 <HR>
119
120
121 <!-- ======= START OF BOTTOM NAVBAR ====== -->
122 <A NAME="navbar_bottom"><!-- --></A>
123 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
124 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
125 <TR>
126 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
127 <A NAME="navbar_bottom_firstrow"><!-- --></A>
128 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
129 <TR ALIGN="center" VALIGN="top">
130 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
131 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
132 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
133 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
134 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
135 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
136 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
137 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
138 </TR>
139 </TABLE>
140 </TD>
141 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
142 </EM>
143 </TD>
144 </TR>
145
146 <TR>
147 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
148 &nbsp;<A HREF="../../../../com/google/gson/annotations/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
149 &nbsp;<A HREF="../../../../com/google/gson/stream/package-summary.html"><B>NEXT PACKAGE</B></A></FONT></TD>
150 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
151 <A HREF="../../../../index.html?com/google/gson/reflect/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
152 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
153 &nbsp;<SCRIPT type="text/javascript">
154 <!--
155 if(window==top) {
156 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
157 }
158 //-->
159 </SCRIPT>
160 <NOSCRIPT>
161 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
162 </NOSCRIPT>
163
164
165 </FONT></TD>
166 </TR>
167 </TABLE>
168 <A NAME="skip-navbar_bottom"></A>
169 <!-- ======== END OF BOTTOM NAVBAR ======= -->
170
171 <HR>
172 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
173 </BODY>
174 </HTML>
+0
-154
gson/docs/javadocs/com/google/gson/reflect/package-tree.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.reflect Class Hierarchy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson.reflect Class Hierarchy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/annotations/package-tree.html"><B>PREV</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/stream/package-tree.html"><B>NEXT</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/reflect/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 Hierarchy For Package com.google.gson.reflect
85 </H2>
86 </CENTER>
87 <DL>
88 <DT><B>Package Hierarchies:</B><DD><A HREF="../../../../overview-tree.html">All Packages</A></DL>
89 <HR>
90 <H2>
91 Class Hierarchy
92 </H2>
93 <UL>
94 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
95 <LI TYPE="circle">com.google.gson.reflect.<A HREF="../../../../com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><B>TypeToken</B></A>&lt;T&gt;</UL>
96 </UL>
97 <HR>
98
99
100 <!-- ======= START OF BOTTOM NAVBAR ====== -->
101 <A NAME="navbar_bottom"><!-- --></A>
102 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
103 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
104 <TR>
105 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
106 <A NAME="navbar_bottom_firstrow"><!-- --></A>
107 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
108 <TR ALIGN="center" VALIGN="top">
109 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
110 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
111 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
112 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
113 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
114 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
115 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
116 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
117 </TR>
118 </TABLE>
119 </TD>
120 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
121 </EM>
122 </TD>
123 </TR>
124
125 <TR>
126 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
127 &nbsp;<A HREF="../../../../com/google/gson/annotations/package-tree.html"><B>PREV</B></A>&nbsp;
128 &nbsp;<A HREF="../../../../com/google/gson/stream/package-tree.html"><B>NEXT</B></A></FONT></TD>
129 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
130 <A HREF="../../../../index.html?com/google/gson/reflect/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
131 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
132 &nbsp;<SCRIPT type="text/javascript">
133 <!--
134 if(window==top) {
135 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
136 }
137 //-->
138 </SCRIPT>
139 <NOSCRIPT>
140 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
141 </NOSCRIPT>
142
143
144 </FONT></TD>
145 </TR>
146 </TABLE>
147 <A NAME="skip-navbar_bottom"></A>
148 <!-- ======== END OF BOTTOM NAVBAR ======= -->
149
150 <HR>
151 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
152 </BODY>
153 </HTML>
+0
-191
gson/docs/javadocs/com/google/gson/reflect/package-use.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Package com.google.gson.reflect (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Package com.google.gson.reflect (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/reflect/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Package<br>com.google.gson.reflect</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 <TR BGCOLOR="white" CLASS="TableRowColor">
98 <TD><A HREF="#com.google.gson.reflect"><B>com.google.gson.reflect</B></A></TD>
99 <TD>This package provides utility classes for finding type information for generic types.&nbsp;</TD>
100 </TR>
101 </TABLE>
102 &nbsp;
103 <P>
104 <A NAME="com.google.gson"><!-- --></A>
105 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
106 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
107 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
108 Classes in <A HREF="../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A> used by <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
109 </TR>
110 <TR BGCOLOR="white" CLASS="TableRowColor">
111 <TD><B><A HREF="../../../../com/google/gson/reflect/class-use/TypeToken.html#com.google.gson"><B>TypeToken</B></A></B>
112
113 <BR>
114 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Represents a generic type <code>T</code>.</TD>
115 </TR>
116 </TABLE>
117 &nbsp;
118 <P>
119 <A NAME="com.google.gson.reflect"><!-- --></A>
120 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
121 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
122 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
123 Classes in <A HREF="../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A> used by <A HREF="../../../../com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A></FONT></TH>
124 </TR>
125 <TR BGCOLOR="white" CLASS="TableRowColor">
126 <TD><B><A HREF="../../../../com/google/gson/reflect/class-use/TypeToken.html#com.google.gson.reflect"><B>TypeToken</B></A></B>
127
128 <BR>
129 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Represents a generic type <code>T</code>.</TD>
130 </TR>
131 </TABLE>
132 &nbsp;
133 <P>
134 <HR>
135
136
137 <!-- ======= START OF BOTTOM NAVBAR ====== -->
138 <A NAME="navbar_bottom"><!-- --></A>
139 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
140 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
141 <TR>
142 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
143 <A NAME="navbar_bottom_firstrow"><!-- --></A>
144 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
145 <TR ALIGN="center" VALIGN="top">
146 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
148 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
149 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
150 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
154 </TR>
155 </TABLE>
156 </TD>
157 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
158 </EM>
159 </TD>
160 </TR>
161
162 <TR>
163 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
164 &nbsp;PREV&nbsp;
165 &nbsp;NEXT</FONT></TD>
166 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
167 <A HREF="../../../../index.html?com/google/gson/reflect/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
168 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
169 &nbsp;<SCRIPT type="text/javascript">
170 <!--
171 if(window==top) {
172 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
173 }
174 //-->
175 </SCRIPT>
176 <NOSCRIPT>
177 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
178 </NOSCRIPT>
179
180
181 </FONT></TD>
182 </TR>
183 </TABLE>
184 <A NAME="skip-navbar_bottom"></A>
185 <!-- ======== END OF BOTTOM NAVBAR ======= -->
186
187 <HR>
188 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
189 </BODY>
190 </HTML>
+0
-970
gson/docs/javadocs/com/google/gson/stream/JsonReader.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonReader (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonReader (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonReader.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV CLASS&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/JsonReader.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonReader.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.stream</FONT>
92 <BR>
93 Class JsonReader</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.stream.JsonReader</B>
97 </PRE>
98 <DL>
99 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A></DD>
100 </DL>
101 <HR>
102 <DL>
103 <DT><PRE>public class <B>JsonReader</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A></DL>
104 </PRE>
105
106 <P>
107 Reads a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
108 encoded value as a stream of tokens. This stream includes both literal
109 values (strings, numbers, booleans, and nulls) as well as the begin and
110 end delimiters of objects and arrays. The tokens are traversed in
111 depth-first order, the same order that they appear in the JSON document.
112 Within JSON objects, name/value pairs are represented by a single token.
113
114 <h3>Parsing JSON</h3>
115 To create a recursive descent parser for your own JSON streams, first create
116 an entry point method that creates a <code>JsonReader</code>.
117
118 <p>Next, create handler methods for each structure in your JSON text. You'll
119 need a method for each object type and for each array type.
120 <ul>
121 <li>Within <strong>array handling</strong> methods, first call <A HREF="../../../../com/google/gson/stream/JsonReader.html#beginArray()"><CODE>beginArray()</CODE></A> to consume the array's opening bracket. Then create a
122 while loop that accumulates values, terminating when <A HREF="../../../../com/google/gson/stream/JsonReader.html#hasNext()"><CODE>hasNext()</CODE></A>
123 is false. Finally, read the array's closing bracket by calling <A HREF="../../../../com/google/gson/stream/JsonReader.html#endArray()"><CODE>endArray()</CODE></A>.
124 <li>Within <strong>object handling</strong> methods, first call <A HREF="../../../../com/google/gson/stream/JsonReader.html#beginObject()"><CODE>beginObject()</CODE></A> to consume the object's opening brace. Then create a
125 while loop that assigns values to local variables based on their name.
126 This loop should terminate when <A HREF="../../../../com/google/gson/stream/JsonReader.html#hasNext()"><CODE>hasNext()</CODE></A> is false. Finally,
127 read the object's closing brace by calling <A HREF="../../../../com/google/gson/stream/JsonReader.html#endObject()"><CODE>endObject()</CODE></A>.
128 </ul>
129 <p>When a nested object or array is encountered, delegate to the
130 corresponding handler method.
131
132 <p>When an unknown name is encountered, strict parsers should fail with an
133 exception. Lenient parsers should call <A HREF="../../../../com/google/gson/stream/JsonReader.html#skipValue()"><CODE>skipValue()</CODE></A> to recursively
134 skip the value's nested tokens, which may otherwise conflict.
135
136 <p>If a value may be null, you should first check using <A HREF="../../../../com/google/gson/stream/JsonReader.html#peek()"><CODE>peek()</CODE></A>.
137 Null literals can be consumed using either <A HREF="../../../../com/google/gson/stream/JsonReader.html#nextNull()"><CODE>nextNull()</CODE></A> or <A HREF="../../../../com/google/gson/stream/JsonReader.html#skipValue()"><CODE>skipValue()</CODE></A>.
138
139 <h3>Example</h3>
140 Suppose we'd like to parse a stream of messages such as the following: <pre> <code>[
141 {
142 "id": 912345678901,
143 "text": "How do I read a JSON stream in Java?",
144 "geo": null,
145 "user": {
146 "name": "json_newb",
147 "followers_count": 41
148 }
149 },
150 {
151 "id": 912345678902,
152 "text": "@json_newb just use JsonReader!",
153 "geo": [50.454722, -104.606667],
154 "user": {
155 "name": "jesse",
156 "followers_count": 2
157 }
158 }
159 ]</code></pre>
160 This code implements the parser for the above structure: <pre> <code>public List&lt;Message&gt; readJsonStream(InputStream in) throws IOException {
161 JsonReader reader = new JsonReader(new InputStreamReader(in, "UTF-8"));
162 try {
163 return readMessagesArray(reader);
164 } finally {
165 reader.close();
166 }
167 }
168
169 public List&lt;Message&gt; readMessagesArray(JsonReader reader) throws IOException {
170 List&lt;Message&gt; messages = new ArrayList&lt;Message&gt;();
171
172 reader.beginArray();
173 while (reader.hasNext()) {
174 messages.add(readMessage(reader));
175 }
176 reader.endArray();
177 return messages;
178 }
179
180 public Message readMessage(JsonReader reader) throws IOException {
181 long id = -1;
182 String text = null;
183 User user = null;
184 List&lt;Double&gt; geo = null;
185
186 reader.beginObject();
187 while (reader.hasNext()) {
188 String name = reader.nextName();
189 if (name.equals("id")) {
190 id = reader.nextLong();
191 } else if (name.equals("text")) {
192 text = reader.nextString();
193 } else if (name.equals("geo") &amp;&amp; reader.peek() != JsonToken.NULL) {
194 geo = readDoublesArray(reader);
195 } else if (name.equals("user")) {
196 user = readUser(reader);
197 } else {
198 reader.skipValue();
199 }
200 }
201 reader.endObject();
202 return new Message(id, text, user, geo);
203 }
204
205 public List&lt;Double&gt; readDoublesArray(JsonReader reader) throws IOException {
206 List&lt;Double&gt; doubles = new ArrayList&lt;Double&gt;();
207
208 reader.beginArray();
209 while (reader.hasNext()) {
210 doubles.add(reader.nextDouble());
211 }
212 reader.endArray();
213 return doubles;
214 }
215
216 public User readUser(JsonReader reader) throws IOException {
217 String username = null;
218 int followersCount = -1;
219
220 reader.beginObject();
221 while (reader.hasNext()) {
222 String name = reader.nextName();
223 if (name.equals("name")) {
224 username = reader.nextString();
225 } else if (name.equals("followers_count")) {
226 followersCount = reader.nextInt();
227 } else {
228 reader.skipValue();
229 }
230 }
231 reader.endObject();
232 return new User(username, followersCount);
233 }</code></pre>
234
235 <h3>Number Handling</h3>
236 This reader permits numeric values to be read as strings and string values to
237 be read as numbers. For example, both elements of the JSON array <code>[1, "1"]</code> may be read using either <A HREF="../../../../com/google/gson/stream/JsonReader.html#nextInt()"><CODE>nextInt()</CODE></A> or <A HREF="../../../../com/google/gson/stream/JsonReader.html#nextString()"><CODE>nextString()</CODE></A>.
238 This behavior is intended to prevent lossy numeric conversions: double is
239 JavaScript's only numeric type and very large values like <code>9007199254740993</code> cannot be represented exactly on that platform. To minimize
240 precision loss, extremely large values should be written and read as strings
241 in JSON.
242
243 <a name="nonexecuteprefix"/><h3>Non-Execute Prefix</h3>
244 Web servers that serve private data using JSON may be vulnerable to <a
245 href="http://en.wikipedia.org/wiki/JSON#Cross-site_request_forgery">Cross-site
246 request forgery</a> attacks. In such an attack, a malicious site gains access
247 to a private JSON file by executing it with an HTML <code>&lt;script&gt;</code> tag.
248
249 <p>Prefixing JSON files with <code>")]}'\n"</code> makes them non-executable
250 by <code>&lt;script&gt;</code> tags, disarming the attack. Since the prefix is malformed
251 JSON, strict parsing fails when it is encountered. This class permits the
252 non-execute prefix when <A HREF="../../../../com/google/gson/stream/JsonReader.html#setLenient(boolean)"><CODE>lenient parsing</CODE></A> is
253 enabled.
254
255 <p>Each <code>JsonReader</code> may be used to read a single JSON stream. Instances
256 of this class are not thread safe.
257 <P>
258
259 <P>
260 <DL>
261 <DT><B>Since:</B></DT>
262 <DD>1.6</DD>
263 <DT><B>Author:</B></DT>
264 <DD>Jesse Wilson</DD>
265 </DL>
266 <HR>
267
268 <P>
269
270 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
271
272 <A NAME="constructor_summary"><!-- --></A>
273 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
274 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
275 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
276 <B>Constructor Summary</B></FONT></TH>
277 </TR>
278 <TR BGCOLOR="white" CLASS="TableRowColor">
279 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#JsonReader(java.io.Reader)">JsonReader</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;in)</CODE>
280
281 <BR>
282 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new instance that reads a JSON-encoded stream from <code>in</code>.</TD>
283 </TR>
284 </TABLE>
285 &nbsp;
286 <!-- ========== METHOD SUMMARY =========== -->
287
288 <A NAME="method_summary"><!-- --></A>
289 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
290 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
291 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
292 <B>Method Summary</B></FONT></TH>
293 </TR>
294 <TR BGCOLOR="white" CLASS="TableRowColor">
295 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
296 <CODE>&nbsp;void</CODE></FONT></TD>
297 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#beginArray()">beginArray</A></B>()</CODE>
298
299 <BR>
300 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Consumes the next token from the JSON stream and asserts that it is the
301 beginning of a new array.</TD>
302 </TR>
303 <TR BGCOLOR="white" CLASS="TableRowColor">
304 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
305 <CODE>&nbsp;void</CODE></FONT></TD>
306 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#beginObject()">beginObject</A></B>()</CODE>
307
308 <BR>
309 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Consumes the next token from the JSON stream and asserts that it is the
310 beginning of a new object.</TD>
311 </TR>
312 <TR BGCOLOR="white" CLASS="TableRowColor">
313 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
314 <CODE>&nbsp;void</CODE></FONT></TD>
315 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#close()">close</A></B>()</CODE>
316
317 <BR>
318 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Closes this JSON reader and the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A>.</TD>
319 </TR>
320 <TR BGCOLOR="white" CLASS="TableRowColor">
321 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
322 <CODE>&nbsp;void</CODE></FONT></TD>
323 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#endArray()">endArray</A></B>()</CODE>
324
325 <BR>
326 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Consumes the next token from the JSON stream and asserts that it is the
327 end of the current array.</TD>
328 </TR>
329 <TR BGCOLOR="white" CLASS="TableRowColor">
330 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
331 <CODE>&nbsp;void</CODE></FONT></TD>
332 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#endObject()">endObject</A></B>()</CODE>
333
334 <BR>
335 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Consumes the next token from the JSON stream and asserts that it is the
336 end of the current object.</TD>
337 </TR>
338 <TR BGCOLOR="white" CLASS="TableRowColor">
339 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
340 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
341 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#getPath()">getPath</A></B>()</CODE>
342
343 <BR>
344 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a <a href="http://goessner.net/articles/JsonPath/">JsonPath</a> to
345 the current location in the JSON value.</TD>
346 </TR>
347 <TR BGCOLOR="white" CLASS="TableRowColor">
348 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
349 <CODE>&nbsp;boolean</CODE></FONT></TD>
350 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#hasNext()">hasNext</A></B>()</CODE>
351
352 <BR>
353 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if the current array or object has another element.</TD>
354 </TR>
355 <TR BGCOLOR="white" CLASS="TableRowColor">
356 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
357 <CODE>&nbsp;boolean</CODE></FONT></TD>
358 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#isLenient()">isLenient</A></B>()</CODE>
359
360 <BR>
361 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if this parser is liberal in what it accepts.</TD>
362 </TR>
363 <TR BGCOLOR="white" CLASS="TableRowColor">
364 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
365 <CODE>&nbsp;boolean</CODE></FONT></TD>
366 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextBoolean()">nextBoolean</A></B>()</CODE>
367
368 <BR>
369 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#BOOLEAN"><CODE>boolean</CODE></A> value of the next token,
370 consuming it.</TD>
371 </TR>
372 <TR BGCOLOR="white" CLASS="TableRowColor">
373 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
374 <CODE>&nbsp;double</CODE></FONT></TD>
375 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextDouble()">nextDouble</A></B>()</CODE>
376
377 <BR>
378 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER"><CODE>double</CODE></A> value of the next token,
379 consuming it.</TD>
380 </TR>
381 <TR BGCOLOR="white" CLASS="TableRowColor">
382 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
383 <CODE>&nbsp;int</CODE></FONT></TD>
384 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextInt()">nextInt</A></B>()</CODE>
385
386 <BR>
387 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER"><CODE>int</CODE></A> value of the next token,
388 consuming it.</TD>
389 </TR>
390 <TR BGCOLOR="white" CLASS="TableRowColor">
391 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
392 <CODE>&nbsp;long</CODE></FONT></TD>
393 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextLong()">nextLong</A></B>()</CODE>
394
395 <BR>
396 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER"><CODE>long</CODE></A> value of the next token,
397 consuming it.</TD>
398 </TR>
399 <TR BGCOLOR="white" CLASS="TableRowColor">
400 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
401 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
402 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextName()">nextName</A></B>()</CODE>
403
404 <BR>
405 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next token, a <A HREF="../../../../com/google/gson/stream/JsonToken.html#NAME"><CODE>property name</CODE></A>, and
406 consumes it.</TD>
407 </TR>
408 <TR BGCOLOR="white" CLASS="TableRowColor">
409 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
410 <CODE>&nbsp;void</CODE></FONT></TD>
411 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextNull()">nextNull</A></B>()</CODE>
412
413 <BR>
414 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Consumes the next token from the JSON stream and asserts that it is a
415 literal null.</TD>
416 </TR>
417 <TR BGCOLOR="white" CLASS="TableRowColor">
418 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
419 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
420 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#nextString()">nextString</A></B>()</CODE>
421
422 <BR>
423 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#STRING"><CODE>string</CODE></A> value of the next token,
424 consuming it.</TD>
425 </TR>
426 <TR BGCOLOR="white" CLASS="TableRowColor">
427 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
428 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></CODE></FONT></TD>
429 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#peek()">peek</A></B>()</CODE>
430
431 <BR>
432 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type of the next token without consuming it.</TD>
433 </TR>
434 <TR BGCOLOR="white" CLASS="TableRowColor">
435 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
436 <CODE>&nbsp;void</CODE></FONT></TD>
437 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#setLenient(boolean)">setLenient</A></B>(boolean&nbsp;lenient)</CODE>
438
439 <BR>
440 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configure this parser to be be liberal in what it accepts.</TD>
441 </TR>
442 <TR BGCOLOR="white" CLASS="TableRowColor">
443 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
444 <CODE>&nbsp;void</CODE></FONT></TD>
445 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#skipValue()">skipValue</A></B>()</CODE>
446
447 <BR>
448 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Skips the next value recursively.</TD>
449 </TR>
450 <TR BGCOLOR="white" CLASS="TableRowColor">
451 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
452 <CODE>&nbsp;<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
453 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonReader.html#toString()">toString</A></B>()</CODE>
454
455 <BR>
456 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
457 </TR>
458 </TABLE>
459 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
460 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
461 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
462 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
463 </TR>
464 <TR BGCOLOR="white" CLASS="TableRowColor">
465 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
466 </TR>
467 </TABLE>
468 &nbsp;
469 <P>
470
471 <!-- ========= CONSTRUCTOR DETAIL ======== -->
472
473 <A NAME="constructor_detail"><!-- --></A>
474 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
475 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
476 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
477 <B>Constructor Detail</B></FONT></TH>
478 </TR>
479 </TABLE>
480
481 <A NAME="JsonReader(java.io.Reader)"><!-- --></A><H3>
482 JsonReader</H3>
483 <PRE>
484 public <B>JsonReader</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io">Reader</A>&nbsp;in)</PRE>
485 <DL>
486 <DD>Creates a new instance that reads a JSON-encoded stream from <code>in</code>.
487 <P>
488 </DL>
489
490 <!-- ============ METHOD DETAIL ========== -->
491
492 <A NAME="method_detail"><!-- --></A>
493 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
494 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
495 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
496 <B>Method Detail</B></FONT></TH>
497 </TR>
498 </TABLE>
499
500 <A NAME="setLenient(boolean)"><!-- --></A><H3>
501 setLenient</H3>
502 <PRE>
503 public final void <B>setLenient</B>(boolean&nbsp;lenient)</PRE>
504 <DL>
505 <DD>Configure this parser to be be liberal in what it accepts. By default,
506 this parser is strict and only accepts JSON as specified by <a
507 href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>. Setting the
508 parser to lenient causes it to ignore the following syntax errors:
509
510 <ul>
511 <li>Streams that start with the <a href="#nonexecuteprefix">non-execute
512 prefix</a>, <code>")]}'\n"</code>.
513 <li>Streams that include multiple top-level values. With strict parsing,
514 each stream must contain exactly one top-level value.
515 <li>Top-level values of any type. With strict parsing, the top-level
516 value must be an object or an array.
517 <li>Numbers may be <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isNaN()" title="class or interface in java.lang"><CODE>NaNs</CODE></A> or <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isInfinite()" title="class or interface in java.lang"><CODE>infinities</CODE></A>.
518 <li>End of line comments starting with <code>//</code> or <code>#</code> and
519 ending with a newline character.
520 <li>C-style comments starting with <code>/*</code> and ending with
521 <code>*</code><code>/</code>. Such comments may not be nested.
522 <li>Names that are unquoted or <code>'single quoted'</code>.
523 <li>Strings that are unquoted or <code>'single quoted'</code>.
524 <li>Array elements separated by <code>;</code> instead of <code>,</code>.
525 <li>Unnecessary array separators. These are interpreted as if null
526 was the omitted value.
527 <li>Names and values separated by <code>=</code> or <code>=&gt;</code> instead of
528 <code>:</code>.
529 <li>Name/value pairs separated by <code>;</code> instead of <code>,</code>.
530 </ul>
531 <P>
532 <DD><DL>
533 </DL>
534 </DD>
535 <DD><DL>
536 </DL>
537 </DD>
538 </DL>
539 <HR>
540
541 <A NAME="isLenient()"><!-- --></A><H3>
542 isLenient</H3>
543 <PRE>
544 public final boolean <B>isLenient</B>()</PRE>
545 <DL>
546 <DD>Returns true if this parser is liberal in what it accepts.
547 <P>
548 <DD><DL>
549 </DL>
550 </DD>
551 <DD><DL>
552 </DL>
553 </DD>
554 </DL>
555 <HR>
556
557 <A NAME="beginArray()"><!-- --></A><H3>
558 beginArray</H3>
559 <PRE>
560 public void <B>beginArray</B>()
561 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
562 <DL>
563 <DD>Consumes the next token from the JSON stream and asserts that it is the
564 beginning of a new array.
565 <P>
566 <DD><DL>
567 </DL>
568 </DD>
569 <DD><DL>
570
571 <DT><B>Throws:</B>
572 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
573 </DD>
574 </DL>
575 <HR>
576
577 <A NAME="endArray()"><!-- --></A><H3>
578 endArray</H3>
579 <PRE>
580 public void <B>endArray</B>()
581 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
582 <DL>
583 <DD>Consumes the next token from the JSON stream and asserts that it is the
584 end of the current array.
585 <P>
586 <DD><DL>
587 </DL>
588 </DD>
589 <DD><DL>
590
591 <DT><B>Throws:</B>
592 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
593 </DD>
594 </DL>
595 <HR>
596
597 <A NAME="beginObject()"><!-- --></A><H3>
598 beginObject</H3>
599 <PRE>
600 public void <B>beginObject</B>()
601 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
602 <DL>
603 <DD>Consumes the next token from the JSON stream and asserts that it is the
604 beginning of a new object.
605 <P>
606 <DD><DL>
607 </DL>
608 </DD>
609 <DD><DL>
610
611 <DT><B>Throws:</B>
612 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
613 </DD>
614 </DL>
615 <HR>
616
617 <A NAME="endObject()"><!-- --></A><H3>
618 endObject</H3>
619 <PRE>
620 public void <B>endObject</B>()
621 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
622 <DL>
623 <DD>Consumes the next token from the JSON stream and asserts that it is the
624 end of the current object.
625 <P>
626 <DD><DL>
627 </DL>
628 </DD>
629 <DD><DL>
630
631 <DT><B>Throws:</B>
632 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
633 </DD>
634 </DL>
635 <HR>
636
637 <A NAME="hasNext()"><!-- --></A><H3>
638 hasNext</H3>
639 <PRE>
640 public boolean <B>hasNext</B>()
641 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
642 <DL>
643 <DD>Returns true if the current array or object has another element.
644 <P>
645 <DD><DL>
646 </DL>
647 </DD>
648 <DD><DL>
649
650 <DT><B>Throws:</B>
651 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
652 </DD>
653 </DL>
654 <HR>
655
656 <A NAME="peek()"><!-- --></A><H3>
657 peek</H3>
658 <PRE>
659 public <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>peek</B>()
660 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
661 <DL>
662 <DD>Returns the type of the next token without consuming it.
663 <P>
664 <DD><DL>
665 </DL>
666 </DD>
667 <DD><DL>
668
669 <DT><B>Throws:</B>
670 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
671 </DD>
672 </DL>
673 <HR>
674
675 <A NAME="nextName()"><!-- --></A><H3>
676 nextName</H3>
677 <PRE>
678 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>nextName</B>()
679 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
680 <DL>
681 <DD>Returns the next token, a <A HREF="../../../../com/google/gson/stream/JsonToken.html#NAME"><CODE>property name</CODE></A>, and
682 consumes it.
683 <P>
684 <DD><DL>
685 </DL>
686 </DD>
687 <DD><DL>
688
689 <DT><B>Throws:</B>
690 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE> - if the next token in the stream is not a property
691 name.</DL>
692 </DD>
693 </DL>
694 <HR>
695
696 <A NAME="nextString()"><!-- --></A><H3>
697 nextString</H3>
698 <PRE>
699 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>nextString</B>()
700 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
701 <DL>
702 <DD>Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#STRING"><CODE>string</CODE></A> value of the next token,
703 consuming it. If the next token is a number, this method will return its
704 string form.
705 <P>
706 <DD><DL>
707 </DL>
708 </DD>
709 <DD><DL>
710
711 <DT><B>Throws:</B>
712 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the next token is not a string or if
713 this reader is closed.
714 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
715 </DD>
716 </DL>
717 <HR>
718
719 <A NAME="nextBoolean()"><!-- --></A><H3>
720 nextBoolean</H3>
721 <PRE>
722 public boolean <B>nextBoolean</B>()
723 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
724 <DL>
725 <DD>Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#BOOLEAN"><CODE>boolean</CODE></A> value of the next token,
726 consuming it.
727 <P>
728 <DD><DL>
729 </DL>
730 </DD>
731 <DD><DL>
732
733 <DT><B>Throws:</B>
734 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the next token is not a boolean or if
735 this reader is closed.
736 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
737 </DD>
738 </DL>
739 <HR>
740
741 <A NAME="nextNull()"><!-- --></A><H3>
742 nextNull</H3>
743 <PRE>
744 public void <B>nextNull</B>()
745 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
746 <DL>
747 <DD>Consumes the next token from the JSON stream and asserts that it is a
748 literal null.
749 <P>
750 <DD><DL>
751 </DL>
752 </DD>
753 <DD><DL>
754
755 <DT><B>Throws:</B>
756 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the next token is not null or if this
757 reader is closed.
758 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
759 </DD>
760 </DL>
761 <HR>
762
763 <A NAME="nextDouble()"><!-- --></A><H3>
764 nextDouble</H3>
765 <PRE>
766 public double <B>nextDouble</B>()
767 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
768 <DL>
769 <DD>Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER"><CODE>double</CODE></A> value of the next token,
770 consuming it. If the next token is a string, this method will attempt to
771 parse it as a double using <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#parseDouble(java.lang.String)" title="class or interface in java.lang"><CODE>Double.parseDouble(String)</CODE></A>.
772 <P>
773 <DD><DL>
774 </DL>
775 </DD>
776 <DD><DL>
777
778 <DT><B>Throws:</B>
779 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the next token is not a literal value.
780 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the next literal value cannot be parsed
781 as a double, or is non-finite.
782 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
783 </DD>
784 </DL>
785 <HR>
786
787 <A NAME="nextLong()"><!-- --></A><H3>
788 nextLong</H3>
789 <PRE>
790 public long <B>nextLong</B>()
791 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
792 <DL>
793 <DD>Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER"><CODE>long</CODE></A> value of the next token,
794 consuming it. If the next token is a string, this method will attempt to
795 parse it as a long. If the next token's numeric value cannot be exactly
796 represented by a Java <code>long</code>, this method throws.
797 <P>
798 <DD><DL>
799 </DL>
800 </DD>
801 <DD><DL>
802
803 <DT><B>Throws:</B>
804 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the next token is not a literal value.
805 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the next literal value cannot be parsed
806 as a number, or exactly represented as a long.
807 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
808 </DD>
809 </DL>
810 <HR>
811
812 <A NAME="nextInt()"><!-- --></A><H3>
813 nextInt</H3>
814 <PRE>
815 public int <B>nextInt</B>()
816 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
817 <DL>
818 <DD>Returns the <A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER"><CODE>int</CODE></A> value of the next token,
819 consuming it. If the next token is a string, this method will attempt to
820 parse it as an int. If the next token's numeric value cannot be exactly
821 represented by a Java <code>int</code>, this method throws.
822 <P>
823 <DD><DL>
824 </DL>
825 </DD>
826 <DD><DL>
827
828 <DT><B>Throws:</B>
829 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang">IllegalStateException</A></CODE> - if the next token is not a literal value.
830 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NumberFormatException.html?is-external=true" title="class or interface in java.lang">NumberFormatException</A></CODE> - if the next literal value cannot be parsed
831 as a number, or exactly represented as an int.
832 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
833 </DD>
834 </DL>
835 <HR>
836
837 <A NAME="close()"><!-- --></A><H3>
838 close</H3>
839 <PRE>
840 public void <B>close</B>()
841 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
842 <DL>
843 <DD>Closes this JSON reader and the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A>.
844 <P>
845 <DD><DL>
846 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true#close()" title="class or interface in java.io">close</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A></CODE></DL>
847 </DD>
848 <DD><DL>
849
850 <DT><B>Throws:</B>
851 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
852 </DD>
853 </DL>
854 <HR>
855
856 <A NAME="skipValue()"><!-- --></A><H3>
857 skipValue</H3>
858 <PRE>
859 public void <B>skipValue</B>()
860 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
861 <DL>
862 <DD>Skips the next value recursively. If it is an object or array, all nested
863 elements are skipped. This method is intended for use when the JSON token
864 stream contains unrecognized or unhandled values.
865 <P>
866 <DD><DL>
867 </DL>
868 </DD>
869 <DD><DL>
870
871 <DT><B>Throws:</B>
872 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
873 </DD>
874 </DL>
875 <HR>
876
877 <A NAME="toString()"><!-- --></A><H3>
878 toString</H3>
879 <PRE>
880 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>toString</B>()</PRE>
881 <DL>
882 <DD><DL>
883 <DT><B>Overrides:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE> in class <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></DL>
884 </DD>
885 <DD><DL>
886 </DL>
887 </DD>
888 </DL>
889 <HR>
890
891 <A NAME="getPath()"><!-- --></A><H3>
892 getPath</H3>
893 <PRE>
894 public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getPath</B>()</PRE>
895 <DL>
896 <DD>Returns a <a href="http://goessner.net/articles/JsonPath/">JsonPath</a> to
897 the current location in the JSON value.
898 <P>
899 <DD><DL>
900 </DL>
901 </DD>
902 <DD><DL>
903 </DL>
904 </DD>
905 </DL>
906 <!-- ========= END OF CLASS DATA ========= -->
907 <HR>
908
909
910 <!-- ======= START OF BOTTOM NAVBAR ====== -->
911 <A NAME="navbar_bottom"><!-- --></A>
912 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
913 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
914 <TR>
915 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
916 <A NAME="navbar_bottom_firstrow"><!-- --></A>
917 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
918 <TR ALIGN="center" VALIGN="top">
919 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
920 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
921 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
922 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonReader.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
923 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
924 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
925 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
926 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
927 </TR>
928 </TABLE>
929 </TD>
930 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
931 </EM>
932 </TD>
933 </TR>
934
935 <TR>
936 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
937 &nbsp;PREV CLASS&nbsp;
938 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>NEXT CLASS</B></A></FONT></TD>
939 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
940 <A HREF="../../../../index.html?com/google/gson/stream/JsonReader.html" target="_top"><B>FRAMES</B></A> &nbsp;
941 &nbsp;<A HREF="JsonReader.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
942 &nbsp;<SCRIPT type="text/javascript">
943 <!--
944 if(window==top) {
945 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
946 }
947 //-->
948 </SCRIPT>
949 <NOSCRIPT>
950 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
951 </NOSCRIPT>
952
953
954 </FONT></TD>
955 </TR>
956 <TR>
957 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
958 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
959 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
960 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
961 </TR>
962 </TABLE>
963 <A NAME="skip-navbar_bottom"></A>
964 <!-- ======== END OF BOTTOM NAVBAR ======= -->
965
966 <HR>
967 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
968 </BODY>
969 </HTML>
+0
-487
gson/docs/javadocs/com/google/gson/stream/JsonToken.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonToken (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonToken (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonToken.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/JsonToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#enum_constant_summary">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;<A HREF="#enum_constant_detail">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.stream</FONT>
92 <BR>
93 Enum JsonToken</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">java.lang.Enum</A>&lt;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>&gt;
97 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.stream.JsonToken</B>
98 </PRE>
99 <DL>
100 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>&gt;</DD>
101 </DL>
102 <HR>
103 <DL>
104 <DT><PRE>public enum <B>JsonToken</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</A>&lt;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>&gt;</DL>
105 </PRE>
106
107 <P>
108 A structure, name or value type in a JSON-encoded string.
109 <P>
110
111 <P>
112 <DL>
113 <DT><B>Since:</B></DT>
114 <DD>1.6</DD>
115 <DT><B>Author:</B></DT>
116 <DD>Jesse Wilson</DD>
117 </DL>
118 <HR>
119
120 <P>
121 <!-- =========== ENUM CONSTANT SUMMARY =========== -->
122
123 <A NAME="enum_constant_summary"><!-- --></A>
124 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
125 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
126 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
127 <B>Enum Constant Summary</B></FONT></TH>
128 </TR>
129 <TR BGCOLOR="white" CLASS="TableRowColor">
130 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#BEGIN_ARRAY">BEGIN_ARRAY</A></B></CODE>
131
132 <BR>
133 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The opening of a JSON array.</TD>
134 </TR>
135 <TR BGCOLOR="white" CLASS="TableRowColor">
136 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#BEGIN_OBJECT">BEGIN_OBJECT</A></B></CODE>
137
138 <BR>
139 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The opening of a JSON object.</TD>
140 </TR>
141 <TR BGCOLOR="white" CLASS="TableRowColor">
142 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#BOOLEAN">BOOLEAN</A></B></CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A JSON <code>true</code> or <code>false</code>.</TD>
146 </TR>
147 <TR BGCOLOR="white" CLASS="TableRowColor">
148 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#END_ARRAY">END_ARRAY</A></B></CODE>
149
150 <BR>
151 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The closing of a JSON array.</TD>
152 </TR>
153 <TR BGCOLOR="white" CLASS="TableRowColor">
154 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#END_DOCUMENT">END_DOCUMENT</A></B></CODE>
155
156 <BR>
157 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The end of the JSON stream.</TD>
158 </TR>
159 <TR BGCOLOR="white" CLASS="TableRowColor">
160 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#END_OBJECT">END_OBJECT</A></B></CODE>
161
162 <BR>
163 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The closing of a JSON object.</TD>
164 </TR>
165 <TR BGCOLOR="white" CLASS="TableRowColor">
166 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#NAME">NAME</A></B></CODE>
167
168 <BR>
169 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A JSON property name.</TD>
170 </TR>
171 <TR BGCOLOR="white" CLASS="TableRowColor">
172 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#NULL">NULL</A></B></CODE>
173
174 <BR>
175 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A JSON <code>null</code>.</TD>
176 </TR>
177 <TR BGCOLOR="white" CLASS="TableRowColor">
178 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#NUMBER">NUMBER</A></B></CODE>
179
180 <BR>
181 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A JSON number represented in this API by a Java <code>double</code>, <code>long</code>, or <code>int</code>.</TD>
182 </TR>
183 <TR BGCOLOR="white" CLASS="TableRowColor">
184 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#STRING">STRING</A></B></CODE>
185
186 <BR>
187 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A JSON string.</TD>
188 </TR>
189 </TABLE>
190 &nbsp;
191 <!-- ========== METHOD SUMMARY =========== -->
192
193 <A NAME="method_summary"><!-- --></A>
194 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
195 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
196 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
197 <B>Method Summary</B></FONT></TH>
198 </TR>
199 <TR BGCOLOR="white" CLASS="TableRowColor">
200 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
201 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></CODE></FONT></TD>
202 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#valueOf(java.lang.String)">valueOf</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
203
204 <BR>
205 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the enum constant of this type with the specified name.</TD>
206 </TR>
207 <TR BGCOLOR="white" CLASS="TableRowColor">
208 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
209 <CODE>static&nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>[]</CODE></FONT></TD>
210 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonToken.html#values()">values</A></B>()</CODE>
211
212 <BR>
213 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an array containing the constants of this enum type, in
214 the order they are declared.</TD>
215 </TR>
216 </TABLE>
217 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Enum"><!-- --></A>
218 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
219 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
220 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang">Enum</A></B></TH>
221 </TR>
222 <TR BGCOLOR="white" CLASS="TableRowColor">
223 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Enum.html?is-external=true#valueOf(java.lang.Class, java.lang.String)" title="class or interface in java.lang">valueOf</A></CODE></TD>
224 </TR>
225 </TABLE>
226 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
227 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
228 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
229 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
230 </TR>
231 <TR BGCOLOR="white" CLASS="TableRowColor">
232 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
233 </TR>
234 </TABLE>
235 &nbsp;
236 <P>
237
238 <!-- ============ ENUM CONSTANT DETAIL =========== -->
239
240 <A NAME="enum_constant_detail"><!-- --></A>
241 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
242 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
243 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
244 <B>Enum Constant Detail</B></FONT></TH>
245 </TR>
246 </TABLE>
247
248 <A NAME="BEGIN_ARRAY"><!-- --></A><H3>
249 BEGIN_ARRAY</H3>
250 <PRE>
251 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>BEGIN_ARRAY</B></PRE>
252 <DL>
253 <DD>The opening of a JSON array. Written using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#beginArray()"><CODE>JsonWriter.beginArray()</CODE></A>
254 and read using <A HREF="../../../../com/google/gson/stream/JsonReader.html#beginArray()"><CODE>JsonReader.beginArray()</CODE></A>.
255 <P>
256 <DL>
257 </DL>
258 </DL>
259 <HR>
260
261 <A NAME="END_ARRAY"><!-- --></A><H3>
262 END_ARRAY</H3>
263 <PRE>
264 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>END_ARRAY</B></PRE>
265 <DL>
266 <DD>The closing of a JSON array. Written using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#endArray()"><CODE>JsonWriter.endArray()</CODE></A>
267 and read using <A HREF="../../../../com/google/gson/stream/JsonReader.html#endArray()"><CODE>JsonReader.endArray()</CODE></A>.
268 <P>
269 <DL>
270 </DL>
271 </DL>
272 <HR>
273
274 <A NAME="BEGIN_OBJECT"><!-- --></A><H3>
275 BEGIN_OBJECT</H3>
276 <PRE>
277 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>BEGIN_OBJECT</B></PRE>
278 <DL>
279 <DD>The opening of a JSON object. Written using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#beginObject()"><CODE>JsonWriter.beginObject()</CODE></A>
280 and read using <A HREF="../../../../com/google/gson/stream/JsonReader.html#beginObject()"><CODE>JsonReader.beginObject()</CODE></A>.
281 <P>
282 <DL>
283 </DL>
284 </DL>
285 <HR>
286
287 <A NAME="END_OBJECT"><!-- --></A><H3>
288 END_OBJECT</H3>
289 <PRE>
290 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>END_OBJECT</B></PRE>
291 <DL>
292 <DD>The closing of a JSON object. Written using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#endObject()"><CODE>JsonWriter.endObject()</CODE></A>
293 and read using <A HREF="../../../../com/google/gson/stream/JsonReader.html#endObject()"><CODE>JsonReader.endObject()</CODE></A>.
294 <P>
295 <DL>
296 </DL>
297 </DL>
298 <HR>
299
300 <A NAME="NAME"><!-- --></A><H3>
301 NAME</H3>
302 <PRE>
303 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>NAME</B></PRE>
304 <DL>
305 <DD>A JSON property name. Within objects, tokens alternate between names and
306 their values. Written using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#name(java.lang.String)"><CODE>JsonWriter.name(java.lang.String)</CODE></A> and read using <A HREF="../../../../com/google/gson/stream/JsonReader.html#nextName()"><CODE>JsonReader.nextName()</CODE></A>
307 <P>
308 <DL>
309 </DL>
310 </DL>
311 <HR>
312
313 <A NAME="STRING"><!-- --></A><H3>
314 STRING</H3>
315 <PRE>
316 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>STRING</B></PRE>
317 <DL>
318 <DD>A JSON string.
319 <P>
320 <DL>
321 </DL>
322 </DL>
323 <HR>
324
325 <A NAME="NUMBER"><!-- --></A><H3>
326 NUMBER</H3>
327 <PRE>
328 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>NUMBER</B></PRE>
329 <DL>
330 <DD>A JSON number represented in this API by a Java <code>double</code>, <code>long</code>, or <code>int</code>.
331 <P>
332 <DL>
333 </DL>
334 </DL>
335 <HR>
336
337 <A NAME="BOOLEAN"><!-- --></A><H3>
338 BOOLEAN</H3>
339 <PRE>
340 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>BOOLEAN</B></PRE>
341 <DL>
342 <DD>A JSON <code>true</code> or <code>false</code>.
343 <P>
344 <DL>
345 </DL>
346 </DL>
347 <HR>
348
349 <A NAME="NULL"><!-- --></A><H3>
350 NULL</H3>
351 <PRE>
352 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>NULL</B></PRE>
353 <DL>
354 <DD>A JSON <code>null</code>.
355 <P>
356 <DL>
357 </DL>
358 </DL>
359 <HR>
360
361 <A NAME="END_DOCUMENT"><!-- --></A><H3>
362 END_DOCUMENT</H3>
363 <PRE>
364 public static final <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>END_DOCUMENT</B></PRE>
365 <DL>
366 <DD>The end of the JSON stream. This sentinel value is returned by <A HREF="../../../../com/google/gson/stream/JsonReader.html#peek()"><CODE>JsonReader.peek()</CODE></A> to signal that the JSON-encoded value has no more
367 tokens.
368 <P>
369 <DL>
370 </DL>
371 </DL>
372
373 <!-- ============ METHOD DETAIL ========== -->
374
375 <A NAME="method_detail"><!-- --></A>
376 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
377 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
378 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
379 <B>Method Detail</B></FONT></TH>
380 </TR>
381 </TABLE>
382
383 <A NAME="values()"><!-- --></A><H3>
384 values</H3>
385 <PRE>
386 public static <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>[] <B>values</B>()</PRE>
387 <DL>
388 <DD>Returns an array containing the constants of this enum type, in
389 the order they are declared. This method may be used to iterate
390 over the constants as follows:
391 <pre>
392 for (JsonToken c : JsonToken.values())
393 &nbsp; System.out.println(c);
394 </pre>
395 <P>
396 <DD><DL>
397
398 <DT><B>Returns:</B><DD>an array containing the constants of this enum type, in
399 the order they are declared</DL>
400 </DD>
401 </DL>
402 <HR>
403
404 <A NAME="valueOf(java.lang.String)"><!-- --></A><H3>
405 valueOf</H3>
406 <PRE>
407 public static <A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> <B>valueOf</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</PRE>
408 <DL>
409 <DD>Returns the enum constant of this type with the specified name.
410 The string must match <I>exactly</I> an identifier used to declare an
411 enum constant in this type. (Extraneous whitespace characters are
412 not permitted.)
413 <P>
414 <DD><DL>
415 <DT><B>Parameters:</B><DD><CODE>name</CODE> - the name of the enum constant to be returned.
416 <DT><B>Returns:</B><DD>the enum constant with the specified name
417 <DT><B>Throws:</B>
418 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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
419 with the specified name
420 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</A></CODE> - if the argument is null</DL>
421 </DD>
422 </DL>
423 <!-- ========= END OF CLASS DATA ========= -->
424 <HR>
425
426
427 <!-- ======= START OF BOTTOM NAVBAR ====== -->
428 <A NAME="navbar_bottom"><!-- --></A>
429 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
430 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
431 <TR>
432 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
433 <A NAME="navbar_bottom_firstrow"><!-- --></A>
434 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
435 <TR ALIGN="center" VALIGN="top">
436 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
437 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
438 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
439 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonToken.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
440 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
441 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
442 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
443 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
444 </TR>
445 </TABLE>
446 </TD>
447 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
448 </EM>
449 </TD>
450 </TR>
451
452 <TR>
453 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
454 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><B>PREV CLASS</B></A>&nbsp;
455 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>NEXT CLASS</B></A></FONT></TD>
456 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
457 <A HREF="../../../../index.html?com/google/gson/stream/JsonToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
458 &nbsp;<A HREF="JsonToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
459 &nbsp;<SCRIPT type="text/javascript">
460 <!--
461 if(window==top) {
462 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
463 }
464 //-->
465 </SCRIPT>
466 <NOSCRIPT>
467 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
468 </NOSCRIPT>
469
470
471 </FONT></TD>
472 </TR>
473 <TR>
474 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
475 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#enum_constant_summary">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
476 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
477 DETAIL:&nbsp;<A HREF="#enum_constant_detail">ENUM CONSTANTS</A>&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
478 </TR>
479 </TABLE>
480 <A NAME="skip-navbar_bottom"></A>
481 <!-- ======== END OF BOTTOM NAVBAR ======= -->
482
483 <HR>
484 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
485 </BODY>
486 </HTML>
+0
-898
gson/docs/javadocs/com/google/gson/stream/JsonWriter.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 JsonWriter (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="JsonWriter (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonWriter.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;<A HREF="../../../../com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><B>NEXT CLASS</B></A></FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/JsonWriter.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonWriter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.stream</FONT>
92 <BR>
93 Class JsonWriter</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.stream.JsonWriter</B>
97 </PRE>
98 <DL>
99 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Flushable.html?is-external=true" title="class or interface in java.io">Flushable</A></DD>
100 </DL>
101 <HR>
102 <DL>
103 <DT><PRE>public class <B>JsonWriter</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Flushable.html?is-external=true" title="class or interface in java.io">Flushable</A></DL>
104 </PRE>
105
106 <P>
107 Writes a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
108 encoded value to a stream, one token at a time. The stream includes both
109 literal values (strings, numbers, booleans and nulls) as well as the begin
110 and end delimiters of objects and arrays.
111
112 <h3>Encoding JSON</h3>
113 To encode your data as JSON, create a new <code>JsonWriter</code>. Each JSON
114 document must contain one top-level array or object. Call methods on the
115 writer as you walk the structure's contents, nesting arrays and objects as
116 necessary:
117 <ul>
118 <li>To write <strong>arrays</strong>, first call <A HREF="../../../../com/google/gson/stream/JsonWriter.html#beginArray()"><CODE>beginArray()</CODE></A>.
119 Write each of the array's elements with the appropriate <A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(java.lang.String)"><CODE>value(java.lang.String)</CODE></A>
120 methods or by nesting other arrays and objects. Finally close the array
121 using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#endArray()"><CODE>endArray()</CODE></A>.
122 <li>To write <strong>objects</strong>, first call <A HREF="../../../../com/google/gson/stream/JsonWriter.html#beginObject()"><CODE>beginObject()</CODE></A>.
123 Write each of the object's properties by alternating calls to
124 <A HREF="../../../../com/google/gson/stream/JsonWriter.html#name(java.lang.String)"><CODE>name(java.lang.String)</CODE></A> with the property's value. Write property values with the
125 appropriate <A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(java.lang.String)"><CODE>value(java.lang.String)</CODE></A> method or by nesting other objects or arrays.
126 Finally close the object using <A HREF="../../../../com/google/gson/stream/JsonWriter.html#endObject()"><CODE>endObject()</CODE></A>.
127 </ul>
128
129 <h3>Example</h3>
130 Suppose we'd like to encode a stream of messages such as the following: <pre> <code>[
131 {
132 "id": 912345678901,
133 "text": "How do I stream JSON in Java?",
134 "geo": null,
135 "user": {
136 "name": "json_newb",
137 "followers_count": 41
138 }
139 },
140 {
141 "id": 912345678902,
142 "text": "@json_newb just use JsonWriter!",
143 "geo": [50.454722, -104.606667],
144 "user": {
145 "name": "jesse",
146 "followers_count": 2
147 }
148 }
149 ]</code></pre>
150 This code encodes the above structure: <pre> <code>public void writeJsonStream(OutputStream out, List&lt;Message&gt; messages) throws IOException {
151 JsonWriter writer = new JsonWriter(new OutputStreamWriter(out, "UTF-8"));
152 writer.setIndentSpaces(4);
153 writeMessagesArray(writer, messages);
154 writer.close();
155 }
156
157 public void writeMessagesArray(JsonWriter writer, List&lt;Message&gt; messages) throws IOException {
158 writer.beginArray();
159 for (Message message : messages) {
160 writeMessage(writer, message);
161 }
162 writer.endArray();
163 }
164
165 public void writeMessage(JsonWriter writer, Message message) throws IOException {
166 writer.beginObject();
167 writer.name("id").value(message.getId());
168 writer.name("text").value(message.getText());
169 if (message.getGeo() != null) {
170 writer.name("geo");
171 writeDoublesArray(writer, message.getGeo());
172 } else {
173 writer.name("geo").nullValue();
174 }
175 writer.name("user");
176 writeUser(writer, message.getUser());
177 writer.endObject();
178 }
179
180 public void writeUser(JsonWriter writer, User user) throws IOException {
181 writer.beginObject();
182 writer.name("name").value(user.getName());
183 writer.name("followers_count").value(user.getFollowersCount());
184 writer.endObject();
185 }
186
187 public void writeDoublesArray(JsonWriter writer, List&lt;Double&gt; doubles) throws IOException {
188 writer.beginArray();
189 for (Double value : doubles) {
190 writer.value(value);
191 }
192 writer.endArray();
193 }</code></pre>
194
195 <p>Each <code>JsonWriter</code> may be used to write a single JSON stream.
196 Instances of this class are not thread safe. Calls that would result in a
197 malformed JSON string will fail with an <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/IllegalStateException.html?is-external=true" title="class or interface in java.lang"><CODE>IllegalStateException</CODE></A>.
198 <P>
199
200 <P>
201 <DL>
202 <DT><B>Since:</B></DT>
203 <DD>1.6</DD>
204 <DT><B>Author:</B></DT>
205 <DD>Jesse Wilson</DD>
206 </DL>
207 <HR>
208
209 <P>
210
211 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
212
213 <A NAME="constructor_summary"><!-- --></A>
214 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
215 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
216 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
217 <B>Constructor Summary</B></FONT></TH>
218 </TR>
219 <TR BGCOLOR="white" CLASS="TableRowColor">
220 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#JsonWriter(java.io.Writer)">JsonWriter</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</A>&nbsp;out)</CODE>
221
222 <BR>
223 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new instance that writes a JSON-encoded stream to <code>out</code>.</TD>
224 </TR>
225 </TABLE>
226 &nbsp;
227 <!-- ========== METHOD SUMMARY =========== -->
228
229 <A NAME="method_summary"><!-- --></A>
230 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
231 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
232 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
233 <B>Method Summary</B></FONT></TH>
234 </TR>
235 <TR BGCOLOR="white" CLASS="TableRowColor">
236 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
237 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
238 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#beginArray()">beginArray</A></B>()</CODE>
239
240 <BR>
241 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Begins encoding a new array.</TD>
242 </TR>
243 <TR BGCOLOR="white" CLASS="TableRowColor">
244 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
245 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
246 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#beginObject()">beginObject</A></B>()</CODE>
247
248 <BR>
249 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Begins encoding a new object.</TD>
250 </TR>
251 <TR BGCOLOR="white" CLASS="TableRowColor">
252 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
253 <CODE>&nbsp;void</CODE></FONT></TD>
254 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#close()">close</A></B>()</CODE>
255
256 <BR>
257 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Flushes and closes this writer and the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>.</TD>
258 </TR>
259 <TR BGCOLOR="white" CLASS="TableRowColor">
260 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
261 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
262 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#endArray()">endArray</A></B>()</CODE>
263
264 <BR>
265 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ends encoding the current array.</TD>
266 </TR>
267 <TR BGCOLOR="white" CLASS="TableRowColor">
268 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
269 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
270 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#endObject()">endObject</A></B>()</CODE>
271
272 <BR>
273 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ends encoding the current object.</TD>
274 </TR>
275 <TR BGCOLOR="white" CLASS="TableRowColor">
276 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
277 <CODE>&nbsp;void</CODE></FONT></TD>
278 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#flush()">flush</A></B>()</CODE>
279
280 <BR>
281 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ensures all buffered data is written to the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>
282 and flushes that writer.</TD>
283 </TR>
284 <TR BGCOLOR="white" CLASS="TableRowColor">
285 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
286 <CODE>&nbsp;boolean</CODE></FONT></TD>
287 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#getSerializeNulls()">getSerializeNulls</A></B>()</CODE>
288
289 <BR>
290 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if object members are serialized when their value is null.</TD>
291 </TR>
292 <TR BGCOLOR="white" CLASS="TableRowColor">
293 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
294 <CODE>&nbsp;boolean</CODE></FONT></TD>
295 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#isHtmlSafe()">isHtmlSafe</A></B>()</CODE>
296
297 <BR>
298 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if this writer writes JSON that's safe for inclusion in HTML
299 and XML documents.</TD>
300 </TR>
301 <TR BGCOLOR="white" CLASS="TableRowColor">
302 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
303 <CODE>&nbsp;boolean</CODE></FONT></TD>
304 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#isLenient()">isLenient</A></B>()</CODE>
305
306 <BR>
307 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns true if this writer has relaxed syntax rules.</TD>
308 </TR>
309 <TR BGCOLOR="white" CLASS="TableRowColor">
310 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
311 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
312 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#name(java.lang.String)">name</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
313
314 <BR>
315 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes the property name.</TD>
316 </TR>
317 <TR BGCOLOR="white" CLASS="TableRowColor">
318 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
319 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
320 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#nullValue()">nullValue</A></B>()</CODE>
321
322 <BR>
323 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>null</code>.</TD>
324 </TR>
325 <TR BGCOLOR="white" CLASS="TableRowColor">
326 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
327 <CODE>&nbsp;void</CODE></FONT></TD>
328 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#setHtmlSafe(boolean)">setHtmlSafe</A></B>(boolean&nbsp;htmlSafe)</CODE>
329
330 <BR>
331 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configure this writer to emit JSON that's safe for direct inclusion in HTML
332 and XML documents.</TD>
333 </TR>
334 <TR BGCOLOR="white" CLASS="TableRowColor">
335 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
336 <CODE>&nbsp;void</CODE></FONT></TD>
337 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#setIndent(java.lang.String)">setIndent</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;indent)</CODE>
338
339 <BR>
340 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the indentation string to be repeated for each level of indentation
341 in the encoded document.</TD>
342 </TR>
343 <TR BGCOLOR="white" CLASS="TableRowColor">
344 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
345 <CODE>&nbsp;void</CODE></FONT></TD>
346 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#setLenient(boolean)">setLenient</A></B>(boolean&nbsp;lenient)</CODE>
347
348 <BR>
349 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Configure this writer to relax its syntax rules.</TD>
350 </TR>
351 <TR BGCOLOR="white" CLASS="TableRowColor">
352 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
353 <CODE>&nbsp;void</CODE></FONT></TD>
354 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#setSerializeNulls(boolean)">setSerializeNulls</A></B>(boolean&nbsp;serializeNulls)</CODE>
355
356 <BR>
357 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets whether object members are serialized when their value is null.</TD>
358 </TR>
359 <TR BGCOLOR="white" CLASS="TableRowColor">
360 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
361 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
362 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(boolean)">value</A></B>(boolean&nbsp;value)</CODE>
363
364 <BR>
365 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
366 </TR>
367 <TR BGCOLOR="white" CLASS="TableRowColor">
368 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
369 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
370 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(double)">value</A></B>(double&nbsp;value)</CODE>
371
372 <BR>
373 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
374 </TR>
375 <TR BGCOLOR="white" CLASS="TableRowColor">
376 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
377 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
378 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(long)">value</A></B>(long&nbsp;value)</CODE>
379
380 <BR>
381 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
382 </TR>
383 <TR BGCOLOR="white" CLASS="TableRowColor">
384 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
385 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
386 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(java.lang.Number)">value</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;value)</CODE>
387
388 <BR>
389 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
390 </TR>
391 <TR BGCOLOR="white" CLASS="TableRowColor">
392 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
393 <CODE>&nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
394 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html#value(java.lang.String)">value</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;value)</CODE>
395
396 <BR>
397 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
398 </TR>
399 </TABLE>
400 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
401 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
402 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
403 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
404 </TR>
405 <TR BGCOLOR="white" CLASS="TableRowColor">
406 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
407 </TR>
408 </TABLE>
409 &nbsp;
410 <P>
411
412 <!-- ========= CONSTRUCTOR DETAIL ======== -->
413
414 <A NAME="constructor_detail"><!-- --></A>
415 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
416 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
417 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
418 <B>Constructor Detail</B></FONT></TH>
419 </TR>
420 </TABLE>
421
422 <A NAME="JsonWriter(java.io.Writer)"><!-- --></A><H3>
423 JsonWriter</H3>
424 <PRE>
425 public <B>JsonWriter</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io">Writer</A>&nbsp;out)</PRE>
426 <DL>
427 <DD>Creates a new instance that writes a JSON-encoded stream to <code>out</code>.
428 For best performance, ensure <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A> is buffered; wrapping in
429 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/BufferedWriter.html?is-external=true" title="class or interface in java.io"><CODE>BufferedWriter</CODE></A> if necessary.
430 <P>
431 </DL>
432
433 <!-- ============ METHOD DETAIL ========== -->
434
435 <A NAME="method_detail"><!-- --></A>
436 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
437 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
438 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
439 <B>Method Detail</B></FONT></TH>
440 </TR>
441 </TABLE>
442
443 <A NAME="setIndent(java.lang.String)"><!-- --></A><H3>
444 setIndent</H3>
445 <PRE>
446 public final void <B>setIndent</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;indent)</PRE>
447 <DL>
448 <DD>Sets the indentation string to be repeated for each level of indentation
449 in the encoded document. If <code>indent.isEmpty()</code> the encoded document
450 will be compact. Otherwise the encoded document will be more
451 human-readable.
452 <P>
453 <DD><DL>
454 </DL>
455 </DD>
456 <DD><DL>
457 <DT><B>Parameters:</B><DD><CODE>indent</CODE> - a string containing only whitespace.</DL>
458 </DD>
459 </DL>
460 <HR>
461
462 <A NAME="setLenient(boolean)"><!-- --></A><H3>
463 setLenient</H3>
464 <PRE>
465 public final void <B>setLenient</B>(boolean&nbsp;lenient)</PRE>
466 <DL>
467 <DD>Configure this writer to relax its syntax rules. By default, this writer
468 only emits well-formed JSON as specified by <a
469 href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>. Setting the writer
470 to lenient permits the following:
471 <ul>
472 <li>Top-level values of any type. With strict writing, the top-level
473 value must be an object or an array.
474 <li>Numbers may be <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isNaN()" title="class or interface in java.lang"><CODE>NaNs</CODE></A> or <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isInfinite()" title="class or interface in java.lang"><CODE>infinities</CODE></A>.
475 </ul>
476 <P>
477 <DD><DL>
478 </DL>
479 </DD>
480 <DD><DL>
481 </DL>
482 </DD>
483 </DL>
484 <HR>
485
486 <A NAME="isLenient()"><!-- --></A><H3>
487 isLenient</H3>
488 <PRE>
489 public boolean <B>isLenient</B>()</PRE>
490 <DL>
491 <DD>Returns true if this writer has relaxed syntax rules.
492 <P>
493 <DD><DL>
494 </DL>
495 </DD>
496 <DD><DL>
497 </DL>
498 </DD>
499 </DL>
500 <HR>
501
502 <A NAME="setHtmlSafe(boolean)"><!-- --></A><H3>
503 setHtmlSafe</H3>
504 <PRE>
505 public final void <B>setHtmlSafe</B>(boolean&nbsp;htmlSafe)</PRE>
506 <DL>
507 <DD>Configure this writer to emit JSON that's safe for direct inclusion in HTML
508 and XML documents. This escapes the HTML characters <code>&lt;</code>, <code>&gt;</code>,
509 <code>&amp;</code> and <code>=</code> before writing them to the stream. Without this
510 setting, your XML/HTML encoder should replace these characters with the
511 corresponding escape sequences.
512 <P>
513 <DD><DL>
514 </DL>
515 </DD>
516 <DD><DL>
517 </DL>
518 </DD>
519 </DL>
520 <HR>
521
522 <A NAME="isHtmlSafe()"><!-- --></A><H3>
523 isHtmlSafe</H3>
524 <PRE>
525 public final boolean <B>isHtmlSafe</B>()</PRE>
526 <DL>
527 <DD>Returns true if this writer writes JSON that's safe for inclusion in HTML
528 and XML documents.
529 <P>
530 <DD><DL>
531 </DL>
532 </DD>
533 <DD><DL>
534 </DL>
535 </DD>
536 </DL>
537 <HR>
538
539 <A NAME="setSerializeNulls(boolean)"><!-- --></A><H3>
540 setSerializeNulls</H3>
541 <PRE>
542 public final void <B>setSerializeNulls</B>(boolean&nbsp;serializeNulls)</PRE>
543 <DL>
544 <DD>Sets whether object members are serialized when their value is null.
545 This has no impact on array elements. The default is true.
546 <P>
547 <DD><DL>
548 </DL>
549 </DD>
550 <DD><DL>
551 </DL>
552 </DD>
553 </DL>
554 <HR>
555
556 <A NAME="getSerializeNulls()"><!-- --></A><H3>
557 getSerializeNulls</H3>
558 <PRE>
559 public final boolean <B>getSerializeNulls</B>()</PRE>
560 <DL>
561 <DD>Returns true if object members are serialized when their value is null.
562 This has no impact on array elements. The default is true.
563 <P>
564 <DD><DL>
565 </DL>
566 </DD>
567 <DD><DL>
568 </DL>
569 </DD>
570 </DL>
571 <HR>
572
573 <A NAME="beginArray()"><!-- --></A><H3>
574 beginArray</H3>
575 <PRE>
576 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>beginArray</B>()
577 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
578 <DL>
579 <DD>Begins encoding a new array. Each call to this method must be paired with
580 a call to <A HREF="../../../../com/google/gson/stream/JsonWriter.html#endArray()"><CODE>endArray()</CODE></A>.
581 <P>
582 <DD><DL>
583 </DL>
584 </DD>
585 <DD><DL>
586
587 <DT><B>Returns:</B><DD>this writer.
588 <DT><B>Throws:</B>
589 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
590 </DD>
591 </DL>
592 <HR>
593
594 <A NAME="endArray()"><!-- --></A><H3>
595 endArray</H3>
596 <PRE>
597 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>endArray</B>()
598 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
599 <DL>
600 <DD>Ends encoding the current array.
601 <P>
602 <DD><DL>
603 </DL>
604 </DD>
605 <DD><DL>
606
607 <DT><B>Returns:</B><DD>this writer.
608 <DT><B>Throws:</B>
609 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
610 </DD>
611 </DL>
612 <HR>
613
614 <A NAME="beginObject()"><!-- --></A><H3>
615 beginObject</H3>
616 <PRE>
617 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>beginObject</B>()
618 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
619 <DL>
620 <DD>Begins encoding a new object. Each call to this method must be paired
621 with a call to <A HREF="../../../../com/google/gson/stream/JsonWriter.html#endObject()"><CODE>endObject()</CODE></A>.
622 <P>
623 <DD><DL>
624 </DL>
625 </DD>
626 <DD><DL>
627
628 <DT><B>Returns:</B><DD>this writer.
629 <DT><B>Throws:</B>
630 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
631 </DD>
632 </DL>
633 <HR>
634
635 <A NAME="endObject()"><!-- --></A><H3>
636 endObject</H3>
637 <PRE>
638 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>endObject</B>()
639 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
640 <DL>
641 <DD>Ends encoding the current object.
642 <P>
643 <DD><DL>
644 </DL>
645 </DD>
646 <DD><DL>
647
648 <DT><B>Returns:</B><DD>this writer.
649 <DT><B>Throws:</B>
650 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
651 </DD>
652 </DL>
653 <HR>
654
655 <A NAME="name(java.lang.String)"><!-- --></A><H3>
656 name</H3>
657 <PRE>
658 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>name</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)
659 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
660 <DL>
661 <DD>Encodes the property name.
662 <P>
663 <DD><DL>
664 </DL>
665 </DD>
666 <DD><DL>
667 <DT><B>Parameters:</B><DD><CODE>name</CODE> - the name of the forthcoming value. May not be null.
668 <DT><B>Returns:</B><DD>this writer.
669 <DT><B>Throws:</B>
670 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
671 </DD>
672 </DL>
673 <HR>
674
675 <A NAME="value(java.lang.String)"><!-- --></A><H3>
676 value</H3>
677 <PRE>
678 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>value</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;value)
679 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
680 <DL>
681 <DD>Encodes <code>value</code>.
682 <P>
683 <DD><DL>
684 </DL>
685 </DD>
686 <DD><DL>
687 <DT><B>Parameters:</B><DD><CODE>value</CODE> - the literal string value, or null to encode a null literal.
688 <DT><B>Returns:</B><DD>this writer.
689 <DT><B>Throws:</B>
690 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
691 </DD>
692 </DL>
693 <HR>
694
695 <A NAME="nullValue()"><!-- --></A><H3>
696 nullValue</H3>
697 <PRE>
698 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>nullValue</B>()
699 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
700 <DL>
701 <DD>Encodes <code>null</code>.
702 <P>
703 <DD><DL>
704 </DL>
705 </DD>
706 <DD><DL>
707
708 <DT><B>Returns:</B><DD>this writer.
709 <DT><B>Throws:</B>
710 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
711 </DD>
712 </DL>
713 <HR>
714
715 <A NAME="value(boolean)"><!-- --></A><H3>
716 value</H3>
717 <PRE>
718 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>value</B>(boolean&nbsp;value)
719 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
720 <DL>
721 <DD>Encodes <code>value</code>.
722 <P>
723 <DD><DL>
724 </DL>
725 </DD>
726 <DD><DL>
727
728 <DT><B>Returns:</B><DD>this writer.
729 <DT><B>Throws:</B>
730 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
731 </DD>
732 </DL>
733 <HR>
734
735 <A NAME="value(double)"><!-- --></A><H3>
736 value</H3>
737 <PRE>
738 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>value</B>(double&nbsp;value)
739 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
740 <DL>
741 <DD>Encodes <code>value</code>.
742 <P>
743 <DD><DL>
744 </DL>
745 </DD>
746 <DD><DL>
747 <DT><B>Parameters:</B><DD><CODE>value</CODE> - a finite value. May not be <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isNaN()" title="class or interface in java.lang"><CODE>NaNs</CODE></A> or
748 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isInfinite()" title="class or interface in java.lang"><CODE>infinities</CODE></A>.
749 <DT><B>Returns:</B><DD>this writer.
750 <DT><B>Throws:</B>
751 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
752 </DD>
753 </DL>
754 <HR>
755
756 <A NAME="value(long)"><!-- --></A><H3>
757 value</H3>
758 <PRE>
759 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>value</B>(long&nbsp;value)
760 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
761 <DL>
762 <DD>Encodes <code>value</code>.
763 <P>
764 <DD><DL>
765 </DL>
766 </DD>
767 <DD><DL>
768
769 <DT><B>Returns:</B><DD>this writer.
770 <DT><B>Throws:</B>
771 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
772 </DD>
773 </DL>
774 <HR>
775
776 <A NAME="value(java.lang.Number)"><!-- --></A><H3>
777 value</H3>
778 <PRE>
779 public <A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> <B>value</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;value)
780 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
781 <DL>
782 <DD>Encodes <code>value</code>.
783 <P>
784 <DD><DL>
785 </DL>
786 </DD>
787 <DD><DL>
788 <DT><B>Parameters:</B><DD><CODE>value</CODE> - a finite value. May not be <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isNaN()" title="class or interface in java.lang"><CODE>NaNs</CODE></A> or
789 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Double.html?is-external=true#isInfinite()" title="class or interface in java.lang"><CODE>infinities</CODE></A>.
790 <DT><B>Returns:</B><DD>this writer.
791 <DT><B>Throws:</B>
792 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
793 </DD>
794 </DL>
795 <HR>
796
797 <A NAME="flush()"><!-- --></A><H3>
798 flush</H3>
799 <PRE>
800 public void <B>flush</B>()
801 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
802 <DL>
803 <DD>Ensures all buffered data is written to the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>
804 and flushes that writer.
805 <P>
806 <DD><DL>
807 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Flushable.html?is-external=true#flush()" title="class or interface in java.io">flush</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Flushable.html?is-external=true" title="class or interface in java.io">Flushable</A></CODE></DL>
808 </DD>
809 <DD><DL>
810
811 <DT><B>Throws:</B>
812 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
813 </DD>
814 </DL>
815 <HR>
816
817 <A NAME="close()"><!-- --></A><H3>
818 close</H3>
819 <PRE>
820 public void <B>close</B>()
821 throws <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
822 <DL>
823 <DD>Flushes and closes this writer and the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>.
824 <P>
825 <DD><DL>
826 <DT><B>Specified by:</B><DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true#close()" title="class or interface in java.io">close</A></CODE> in interface <CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A></CODE></DL>
827 </DD>
828 <DD><DL>
829
830 <DT><B>Throws:</B>
831 <DD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE> - if the JSON document is incomplete.</DL>
832 </DD>
833 </DL>
834 <!-- ========= END OF CLASS DATA ========= -->
835 <HR>
836
837
838 <!-- ======= START OF BOTTOM NAVBAR ====== -->
839 <A NAME="navbar_bottom"><!-- --></A>
840 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
841 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
842 <TR>
843 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
844 <A NAME="navbar_bottom_firstrow"><!-- --></A>
845 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
846 <TR ALIGN="center" VALIGN="top">
847 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
848 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
849 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
850 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/JsonWriter.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
851 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
852 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
853 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
854 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
855 </TR>
856 </TABLE>
857 </TD>
858 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
859 </EM>
860 </TD>
861 </TR>
862
863 <TR>
864 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
865 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>PREV CLASS</B></A>&nbsp;
866 &nbsp;<A HREF="../../../../com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><B>NEXT CLASS</B></A></FONT></TD>
867 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
868 <A HREF="../../../../index.html?com/google/gson/stream/JsonWriter.html" target="_top"><B>FRAMES</B></A> &nbsp;
869 &nbsp;<A HREF="JsonWriter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
870 &nbsp;<SCRIPT type="text/javascript">
871 <!--
872 if(window==top) {
873 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
874 }
875 //-->
876 </SCRIPT>
877 <NOSCRIPT>
878 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
879 </NOSCRIPT>
880
881
882 </FONT></TD>
883 </TR>
884 <TR>
885 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
886 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
887 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
888 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
889 </TR>
890 </TABLE>
891 <A NAME="skip-navbar_bottom"></A>
892 <!-- ======== END OF BOTTOM NAVBAR ======= -->
893
894 <HR>
895 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
896 </BODY>
897 </HTML>
+0
-277
gson/docs/javadocs/com/google/gson/stream/MalformedJsonException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 MalformedJsonException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="MalformedJsonException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/MalformedJsonException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>PREV CLASS</B></A>&nbsp;
59 &nbsp;NEXT CLASS</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/MalformedJsonException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="MalformedJsonException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 <TR>
78 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
80 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
82 </TR>
83 </TABLE>
84 <A NAME="skip-navbar_top"></A>
85 <!-- ========= END OF TOP NAVBAR ========= -->
86
87 <HR>
88 <!-- ======== START OF CLASS DATA ======== -->
89 <H2>
90 <FONT SIZE="-1">
91 com.google.gson.stream</FONT>
92 <BR>
93 Class MalformedJsonException</H2>
94 <PRE>
95 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">java.lang.Throwable</A>
97 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang">java.lang.Exception</A>
98 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">java.io.IOException</A>
99 <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>com.google.gson.stream.MalformedJsonException</B>
100 </PRE>
101 <DL>
102 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A></DD>
103 </DL>
104 <HR>
105 <DL>
106 <DT><PRE>public final class <B>MalformedJsonException</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></DL>
107 </PRE>
108
109 <P>
110 Thrown when a reader encounters malformed JSON. Some syntax errors can be
111 ignored by calling <A HREF="../../../../com/google/gson/stream/JsonReader.html#setLenient(boolean)"><CODE>JsonReader.setLenient(boolean)</CODE></A>.
112 <P>
113
114 <P>
115 <DL>
116 <DT><B>See Also:</B><DD><A HREF="../../../../serialized-form.html#com.google.gson.stream.MalformedJsonException">Serialized Form</A></DL>
117 <HR>
118
119 <P>
120
121 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
122
123 <A NAME="constructor_summary"><!-- --></A>
124 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
125 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
126 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
127 <B>Constructor Summary</B></FONT></TH>
128 </TR>
129 <TR BGCOLOR="white" CLASS="TableRowColor">
130 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/MalformedJsonException.html#MalformedJsonException(java.lang.String)">MalformedJsonException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</CODE>
131
132 <BR>
133 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
134 </TR>
135 <TR BGCOLOR="white" CLASS="TableRowColor">
136 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/MalformedJsonException.html#MalformedJsonException(java.lang.String, java.lang.Throwable)">MalformedJsonException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
137 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;throwable)</CODE>
138
139 <BR>
140 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
141 </TR>
142 <TR BGCOLOR="white" CLASS="TableRowColor">
143 <TD><CODE><B><A HREF="../../../../com/google/gson/stream/MalformedJsonException.html#MalformedJsonException(java.lang.Throwable)">MalformedJsonException</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;throwable)</CODE>
144
145 <BR>
146 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
147 </TR>
148 </TABLE>
149 &nbsp;
150 <!-- ========== METHOD SUMMARY =========== -->
151
152 <A NAME="method_summary"><!-- --></A>
153 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
154 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
155 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
156 <B>Method Summary</B></FONT></TH>
157 </TR>
158 </TABLE>
159 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Throwable"><!-- --></A>
160 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
161 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
162 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A></B></TH>
163 </TR>
164 <TR BGCOLOR="white" CLASS="TableRowColor">
165 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#fillInStackTrace()" title="class or interface in java.lang">fillInStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getCause()" title="class or interface in java.lang">getCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getLocalizedMessage()" title="class or interface in java.lang">getLocalizedMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getMessage()" title="class or interface in java.lang">getMessage</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#getStackTrace()" title="class or interface in java.lang">getStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#initCause(java.lang.Throwable)" title="class or interface in java.lang">initCause</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace()" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintStream)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#printStackTrace(java.io.PrintWriter)" title="class or interface in java.lang">printStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#setStackTrace(java.lang.StackTraceElement[])" title="class or interface in java.lang">setStackTrace</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true#toString()" title="class or interface in java.lang">toString</A></CODE></TD>
166 </TR>
167 </TABLE>
168 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
169 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
170 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
171 <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
172 </TR>
173 <TR BGCOLOR="white" CLASS="TableRowColor">
174 <TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/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/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
175 </TR>
176 </TABLE>
177 &nbsp;
178 <P>
179
180 <!-- ========= CONSTRUCTOR DETAIL ======== -->
181
182 <A NAME="constructor_detail"><!-- --></A>
183 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
184 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
185 <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
186 <B>Constructor Detail</B></FONT></TH>
187 </TR>
188 </TABLE>
189
190 <A NAME="MalformedJsonException(java.lang.String)"><!-- --></A><H3>
191 MalformedJsonException</H3>
192 <PRE>
193 public <B>MalformedJsonException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg)</PRE>
194 <DL>
195 </DL>
196 <HR>
197
198 <A NAME="MalformedJsonException(java.lang.String, java.lang.Throwable)"><!-- --></A><H3>
199 MalformedJsonException</H3>
200 <PRE>
201 public <B>MalformedJsonException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;msg,
202 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;throwable)</PRE>
203 <DL>
204 </DL>
205 <HR>
206
207 <A NAME="MalformedJsonException(java.lang.Throwable)"><!-- --></A><H3>
208 MalformedJsonException</H3>
209 <PRE>
210 public <B>MalformedJsonException</B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang">Throwable</A>&nbsp;throwable)</PRE>
211 <DL>
212 </DL>
213 <!-- ========= END OF CLASS DATA ========= -->
214 <HR>
215
216
217 <!-- ======= START OF BOTTOM NAVBAR ====== -->
218 <A NAME="navbar_bottom"><!-- --></A>
219 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
220 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
221 <TR>
222 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
223 <A NAME="navbar_bottom_firstrow"><!-- --></A>
224 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
225 <TR ALIGN="center" VALIGN="top">
226 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
227 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
228 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
229 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/MalformedJsonException.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
230 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
231 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
232 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
233 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
234 </TR>
235 </TABLE>
236 </TD>
237 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
238 </EM>
239 </TD>
240 </TR>
241
242 <TR>
243 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
244 &nbsp;<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>PREV CLASS</B></A>&nbsp;
245 &nbsp;NEXT CLASS</FONT></TD>
246 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
247 <A HREF="../../../../index.html?com/google/gson/stream/MalformedJsonException.html" target="_top"><B>FRAMES</B></A> &nbsp;
248 &nbsp;<A HREF="MalformedJsonException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
249 &nbsp;<SCRIPT type="text/javascript">
250 <!--
251 if(window==top) {
252 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
253 }
254 //-->
255 </SCRIPT>
256 <NOSCRIPT>
257 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
258 </NOSCRIPT>
259
260
261 </FONT></TD>
262 </TR>
263 <TR>
264 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
265 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#methods_inherited_from_class_java.lang.Throwable">METHOD</A></FONT></TD>
266 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
267 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;METHOD</FONT></TD>
268 </TR>
269 </TABLE>
270 <A NAME="skip-navbar_bottom"></A>
271 <!-- ======== END OF BOTTOM NAVBAR ======= -->
272
273 <HR>
274 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
275 </BODY>
276 </HTML>
+0
-208
gson/docs/javadocs/com/google/gson/stream/class-use/JsonReader.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.stream.JsonReader (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.stream.JsonReader (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/stream//class-useJsonReader.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonReader.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.stream.JsonReader</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 </TABLE>
98 &nbsp;
99 <P>
100 <A NAME="com.google.gson"><!-- --></A>
101 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
102 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
103 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
104 Uses of <A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A> in <A HREF="../../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
105 </TR>
106 </TABLE>
107 &nbsp;
108 <P>
109
110 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
111 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
112 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A></FONT></TH>
113 </TR>
114 <TR BGCOLOR="white" CLASS="TableRowColor">
115 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
116 <CODE>
117 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
118 <TR ALIGN="right" VALIGN="">
119 <TD NOWRAP><FONT SIZE="-1">
120 <CODE>&lt;T&gt; T</CODE></FONT></TD>
121 </TR>
122 </TABLE>
123 </CODE></FONT></TD>
124 <TD><CODE><B>Gson.</B><B><A HREF="../../../../../com/google/gson/Gson.html#fromJson(com.google.gson.stream.JsonReader, java.lang.reflect.Type)">fromJson</A></B>(<A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;reader,
125 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfT)</CODE>
126
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads the next JSON value from <code>reader</code> and convert it to an object
129 of type <code>typeOfT</code>.</TD>
130 </TR>
131 <TR BGCOLOR="white" CLASS="TableRowColor">
132 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
133 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A></CODE></FONT></TD>
134 <TD><CODE><B>JsonParser.</B><B><A HREF="../../../../../com/google/gson/JsonParser.html#parse(com.google.gson.stream.JsonReader)">parse</A></B>(<A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;json)</CODE>
135
136 <BR>
137 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the next value from the JSON stream as a parse tree.</TD>
138 </TR>
139 <TR BGCOLOR="white" CLASS="TableRowColor">
140 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
141 <CODE>abstract &nbsp;<A HREF="../../../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A></CODE></FONT></TD>
142 <TD><CODE><B>TypeAdapter.</B><B><A HREF="../../../../../com/google/gson/TypeAdapter.html#read(com.google.gson.stream.JsonReader)">read</A></B>(<A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>&nbsp;in)</CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads one JSON value (an array, object, string, number, boolean or null)
146 and converts it to a Java object.</TD>
147 </TR>
148 </TABLE>
149 &nbsp;
150 <P>
151 <HR>
152
153
154 <!-- ======= START OF BOTTOM NAVBAR ====== -->
155 <A NAME="navbar_bottom"><!-- --></A>
156 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
157 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
158 <TR>
159 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
160 <A NAME="navbar_bottom_firstrow"><!-- --></A>
161 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
162 <TR ALIGN="center" VALIGN="top">
163 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
164 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
165 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
166 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
167 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
168 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
169 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
170 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
171 </TR>
172 </TABLE>
173 </TD>
174 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
175 </EM>
176 </TD>
177 </TR>
178
179 <TR>
180 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
181 &nbsp;PREV&nbsp;
182 &nbsp;NEXT</FONT></TD>
183 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
184 <A HREF="../../../../../index.html?com/google/gson/stream//class-useJsonReader.html" target="_top"><B>FRAMES</B></A> &nbsp;
185 &nbsp;<A HREF="JsonReader.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
186 &nbsp;<SCRIPT type="text/javascript">
187 <!--
188 if(window==top) {
189 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
190 }
191 //-->
192 </SCRIPT>
193 <NOSCRIPT>
194 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
195 </NOSCRIPT>
196
197
198 </FONT></TD>
199 </TR>
200 </TABLE>
201 <A NAME="skip-navbar_bottom"></A>
202 <!-- ======== END OF BOTTOM NAVBAR ======= -->
203
204 <HR>
205 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
206 </BODY>
207 </HTML>
+0
-198
gson/docs/javadocs/com/google/gson/stream/class-use/JsonToken.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.stream.JsonToken (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.stream.JsonToken (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/stream//class-useJsonToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.stream.JsonToken</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson.stream"><B>com.google.gson.stream</B></A></TD>
94 <TD>&nbsp;&nbsp;</TD>
95 </TR>
96 </TABLE>
97 &nbsp;
98 <P>
99 <A NAME="com.google.gson.stream"><!-- --></A>
100 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
101 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
102 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
103 Uses of <A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A> in <A HREF="../../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A></FONT></TH>
104 </TR>
105 </TABLE>
106 &nbsp;
107 <P>
108
109 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
110 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
111 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A> that return <A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></FONT></TH>
112 </TR>
113 <TR BGCOLOR="white" CLASS="TableRowColor">
114 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
115 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></CODE></FONT></TD>
116 <TD><CODE><B>JsonReader.</B><B><A HREF="../../../../../com/google/gson/stream/JsonReader.html#peek()">peek</A></B>()</CODE>
117
118 <BR>
119 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the type of the next token without consuming it.</TD>
120 </TR>
121 <TR BGCOLOR="white" CLASS="TableRowColor">
122 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
123 <CODE>static&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></CODE></FONT></TD>
124 <TD><CODE><B>JsonToken.</B><B><A HREF="../../../../../com/google/gson/stream/JsonToken.html#valueOf(java.lang.String)">valueOf</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
125
126 <BR>
127 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the enum constant of this type with the specified name.</TD>
128 </TR>
129 <TR BGCOLOR="white" CLASS="TableRowColor">
130 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
131 <CODE>static&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>[]</CODE></FONT></TD>
132 <TD><CODE><B>JsonToken.</B><B><A HREF="../../../../../com/google/gson/stream/JsonToken.html#values()">values</A></B>()</CODE>
133
134 <BR>
135 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns an array containing the constants of this enum type, in
136 the order they are declared.</TD>
137 </TR>
138 </TABLE>
139 &nbsp;
140 <P>
141 <HR>
142
143
144 <!-- ======= START OF BOTTOM NAVBAR ====== -->
145 <A NAME="navbar_bottom"><!-- --></A>
146 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
147 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
148 <TR>
149 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
150 <A NAME="navbar_bottom_firstrow"><!-- --></A>
151 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
152 <TR ALIGN="center" VALIGN="top">
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
155 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
156 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
157 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
158 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
159 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
160 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
161 </TR>
162 </TABLE>
163 </TD>
164 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
165 </EM>
166 </TD>
167 </TR>
168
169 <TR>
170 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
171 &nbsp;PREV&nbsp;
172 &nbsp;NEXT</FONT></TD>
173 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
174 <A HREF="../../../../../index.html?com/google/gson/stream//class-useJsonToken.html" target="_top"><B>FRAMES</B></A> &nbsp;
175 &nbsp;<A HREF="JsonToken.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
176 &nbsp;<SCRIPT type="text/javascript">
177 <!--
178 if(window==top) {
179 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
180 }
181 //-->
182 </SCRIPT>
183 <NOSCRIPT>
184 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
185 </NOSCRIPT>
186
187
188 </FONT></TD>
189 </TR>
190 </TABLE>
191 <A NAME="skip-navbar_bottom"></A>
192 <!-- ======== END OF BOTTOM NAVBAR ======= -->
193
194 <HR>
195 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
196 </BODY>
197 </HTML>
+0
-313
gson/docs/javadocs/com/google/gson/stream/class-use/JsonWriter.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.stream.JsonWriter (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.stream.JsonWriter (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/stream//class-useJsonWriter.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="JsonWriter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.stream.JsonWriter</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 <TR BGCOLOR="white" CLASS="TableRowColor">
98 <TD><A HREF="#com.google.gson.stream"><B>com.google.gson.stream</B></A></TD>
99 <TD>&nbsp;&nbsp;</TD>
100 </TR>
101 </TABLE>
102 &nbsp;
103 <P>
104 <A NAME="com.google.gson"><!-- --></A>
105 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
106 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
107 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
108 Uses of <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> in <A HREF="../../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
109 </TR>
110 </TABLE>
111 &nbsp;
112 <P>
113
114 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
115 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
116 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/package-summary.html">com.google.gson</A> with parameters of type <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></FONT></TH>
117 </TR>
118 <TR BGCOLOR="white" CLASS="TableRowColor">
119 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
120 <CODE>&nbsp;void</CODE></FONT></TD>
121 <TD><CODE><B>Gson.</B><B><A HREF="../../../../../com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="../../../../../com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>&nbsp;jsonElement,
122 <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
123
124 <BR>
125 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON for <code>jsonElement</code> to <code>writer</code>.</TD>
126 </TR>
127 <TR BGCOLOR="white" CLASS="TableRowColor">
128 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
129 <CODE>&nbsp;void</CODE></FONT></TD>
130 <TD><CODE><B>Gson.</B><B><A HREF="../../../../../com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, com.google.gson.stream.JsonWriter)">toJson</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;src,
131 <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</A>&nbsp;typeOfSrc,
132 <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;writer)</CODE>
133
134 <BR>
135 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the JSON representation of <code>src</code> of type <code>typeOfSrc</code> to
136 <code>writer</code>.</TD>
137 </TR>
138 <TR BGCOLOR="white" CLASS="TableRowColor">
139 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
140 <CODE>abstract &nbsp;void</CODE></FONT></TD>
141 <TD><CODE><B>TypeAdapter.</B><B><A HREF="../../../../../com/google/gson/TypeAdapter.html#write(com.google.gson.stream.JsonWriter, T)">write</A></B>(<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>&nbsp;out,
142 <A HREF="../../../../../com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&nbsp;value)</CODE>
143
144 <BR>
145 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes one JSON value (an array, object, string, number, boolean or null)
146 for <code>value</code>.</TD>
147 </TR>
148 </TABLE>
149 &nbsp;
150 <P>
151 <A NAME="com.google.gson.stream"><!-- --></A>
152 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
153 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
154 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
155 Uses of <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A> in <A HREF="../../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A></FONT></TH>
156 </TR>
157 </TABLE>
158 &nbsp;
159 <P>
160
161 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
162 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
163 <TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A> that return <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></FONT></TH>
164 </TR>
165 <TR BGCOLOR="white" CLASS="TableRowColor">
166 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
167 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
168 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#beginArray()">beginArray</A></B>()</CODE>
169
170 <BR>
171 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Begins encoding a new array.</TD>
172 </TR>
173 <TR BGCOLOR="white" CLASS="TableRowColor">
174 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
175 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
176 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#beginObject()">beginObject</A></B>()</CODE>
177
178 <BR>
179 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Begins encoding a new object.</TD>
180 </TR>
181 <TR BGCOLOR="white" CLASS="TableRowColor">
182 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
183 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
184 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#endArray()">endArray</A></B>()</CODE>
185
186 <BR>
187 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ends encoding the current array.</TD>
188 </TR>
189 <TR BGCOLOR="white" CLASS="TableRowColor">
190 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
191 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
192 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#endObject()">endObject</A></B>()</CODE>
193
194 <BR>
195 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Ends encoding the current object.</TD>
196 </TR>
197 <TR BGCOLOR="white" CLASS="TableRowColor">
198 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
199 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
200 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#name(java.lang.String)">name</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;name)</CODE>
201
202 <BR>
203 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes the property name.</TD>
204 </TR>
205 <TR BGCOLOR="white" CLASS="TableRowColor">
206 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
207 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
208 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#nullValue()">nullValue</A></B>()</CODE>
209
210 <BR>
211 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>null</code>.</TD>
212 </TR>
213 <TR BGCOLOR="white" CLASS="TableRowColor">
214 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
215 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
216 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#value(boolean)">value</A></B>(boolean&nbsp;value)</CODE>
217
218 <BR>
219 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
220 </TR>
221 <TR BGCOLOR="white" CLASS="TableRowColor">
222 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
223 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
224 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#value(double)">value</A></B>(double&nbsp;value)</CODE>
225
226 <BR>
227 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
228 </TR>
229 <TR BGCOLOR="white" CLASS="TableRowColor">
230 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
231 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
232 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#value(long)">value</A></B>(long&nbsp;value)</CODE>
233
234 <BR>
235 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
236 </TR>
237 <TR BGCOLOR="white" CLASS="TableRowColor">
238 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
239 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
240 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#value(java.lang.Number)">value</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang">Number</A>&nbsp;value)</CODE>
241
242 <BR>
243 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
244 </TR>
245 <TR BGCOLOR="white" CLASS="TableRowColor">
246 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
247 <CODE>&nbsp;<A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></CODE></FONT></TD>
248 <TD><CODE><B>JsonWriter.</B><B><A HREF="../../../../../com/google/gson/stream/JsonWriter.html#value(java.lang.String)">value</A></B>(<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;value)</CODE>
249
250 <BR>
251 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Encodes <code>value</code>.</TD>
252 </TR>
253 </TABLE>
254 &nbsp;
255 <P>
256 <HR>
257
258
259 <!-- ======= START OF BOTTOM NAVBAR ====== -->
260 <A NAME="navbar_bottom"><!-- --></A>
261 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
262 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
263 <TR>
264 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
265 <A NAME="navbar_bottom_firstrow"><!-- --></A>
266 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
267 <TR ALIGN="center" VALIGN="top">
268 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
269 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
270 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
271 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
272 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
273 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
274 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
275 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
276 </TR>
277 </TABLE>
278 </TD>
279 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
280 </EM>
281 </TD>
282 </TR>
283
284 <TR>
285 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
286 &nbsp;PREV&nbsp;
287 &nbsp;NEXT</FONT></TD>
288 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
289 <A HREF="../../../../../index.html?com/google/gson/stream//class-useJsonWriter.html" target="_top"><B>FRAMES</B></A> &nbsp;
290 &nbsp;<A HREF="JsonWriter.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
291 &nbsp;<SCRIPT type="text/javascript">
292 <!--
293 if(window==top) {
294 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
295 }
296 //-->
297 </SCRIPT>
298 <NOSCRIPT>
299 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
300 </NOSCRIPT>
301
302
303 </FONT></TD>
304 </TR>
305 </TABLE>
306 <A NAME="skip-navbar_bottom"></A>
307 <!-- ======== END OF BOTTOM NAVBAR ======= -->
308
309 <HR>
310 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
311 </BODY>
312 </HTML>
+0
-145
gson/docs/javadocs/com/google/gson/stream/class-use/MalformedJsonException.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Class com.google.gson.stream.MalformedJsonException (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Class com.google.gson.stream.MalformedJsonException (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../../index.html?com/google/gson/stream//class-useMalformedJsonException.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="MalformedJsonException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Class<br>com.google.gson.stream.MalformedJsonException</B></H2>
85 </CENTER>
86 No usage of com.google.gson.stream.MalformedJsonException
87 <P>
88 <HR>
89
90
91 <!-- ======= START OF BOTTOM NAVBAR ====== -->
92 <A NAME="navbar_bottom"><!-- --></A>
93 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
94 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
95 <TR>
96 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
97 <A NAME="navbar_bottom_firstrow"><!-- --></A>
98 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
99 <TR ALIGN="center" VALIGN="top">
100 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
101 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
108 </TR>
109 </TABLE>
110 </TD>
111 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
112 </EM>
113 </TD>
114 </TR>
115
116 <TR>
117 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
118 &nbsp;PREV&nbsp;
119 &nbsp;NEXT</FONT></TD>
120 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
121 <A HREF="../../../../../index.html?com/google/gson/stream//class-useMalformedJsonException.html" target="_top"><B>FRAMES</B></A> &nbsp;
122 &nbsp;<A HREF="MalformedJsonException.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
123 &nbsp;<SCRIPT type="text/javascript">
124 <!--
125 if(window==top) {
126 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
127 }
128 //-->
129 </SCRIPT>
130 <NOSCRIPT>
131 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
132 </NOSCRIPT>
133
134
135 </FONT></TD>
136 </TR>
137 </TABLE>
138 <A NAME="skip-navbar_bottom"></A>
139 <!-- ======== END OF BOTTOM NAVBAR ======= -->
140
141 <HR>
142 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
143 </BODY>
144 </HTML>
+0
-57
gson/docs/javadocs/com/google/gson/stream/package-frame.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.stream (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18 <FONT size="+1" CLASS="FrameTitleFont">
19 <A HREF="../../../../com/google/gson/stream/package-summary.html" target="classFrame">com.google.gson.stream</A></FONT>
20 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
21 <TR>
22 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
23 Classes</FONT>&nbsp;
24 <FONT CLASS="FrameItemFont">
25 <BR>
26 <A HREF="JsonReader.html" title="class in com.google.gson.stream" target="classFrame">JsonReader</A>
27 <BR>
28 <A HREF="JsonWriter.html" title="class in com.google.gson.stream" target="classFrame">JsonWriter</A></FONT></TD>
29 </TR>
30 </TABLE>
31
32
33 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
34 <TR>
35 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
36 Enums</FONT>&nbsp;
37 <FONT CLASS="FrameItemFont">
38 <BR>
39 <A HREF="JsonToken.html" title="enum in com.google.gson.stream" target="classFrame">JsonToken</A></FONT></TD>
40 </TR>
41 </TABLE>
42
43
44 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
45 <TR>
46 <TD NOWRAP><FONT size="+1" CLASS="FrameHeadingFont">
47 Exceptions</FONT>&nbsp;
48 <FONT CLASS="FrameItemFont">
49 <BR>
50 <A HREF="MalformedJsonException.html" title="class in com.google.gson.stream" target="classFrame">MalformedJsonException</A></FONT></TD>
51 </TR>
52 </TABLE>
53
54
55 </BODY>
56 </HTML>
+0
-192
gson/docs/javadocs/com/google/gson/stream/package-summary.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.stream (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson.stream (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
59 &nbsp;NEXT PACKAGE</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <H2>
83 Package com.google.gson.stream
84 </H2>
85
86 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
87 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
88 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
89 <B>Class Summary</B></FONT></TH>
90 </TR>
91 <TR BGCOLOR="white" CLASS="TableRowColor">
92 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A></B></TD>
93 <TD>Reads a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
94 encoded value as a stream of tokens.</TD>
95 </TR>
96 <TR BGCOLOR="white" CLASS="TableRowColor">
97 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A></B></TD>
98 <TD>Writes a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
99 encoded value to a stream, one token at a time.</TD>
100 </TR>
101 </TABLE>
102 &nbsp;
103
104 <P>
105
106 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
107 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
108 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
109 <B>Enum Summary</B></FONT></TH>
110 </TR>
111 <TR BGCOLOR="white" CLASS="TableRowColor">
112 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A></B></TD>
113 <TD>A structure, name or value type in a JSON-encoded string.</TD>
114 </TR>
115 </TABLE>
116 &nbsp;
117
118 <P>
119
120 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
121 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
122 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
123 <B>Exception Summary</B></FONT></TH>
124 </TR>
125 <TR BGCOLOR="white" CLASS="TableRowColor">
126 <TD WIDTH="15%"><B><A HREF="../../../../com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream">MalformedJsonException</A></B></TD>
127 <TD>Thrown when a reader encounters malformed JSON.</TD>
128 </TR>
129 </TABLE>
130 &nbsp;
131
132 <P>
133 <DL>
134 </DL>
135 <HR>
136
137
138 <!-- ======= START OF BOTTOM NAVBAR ====== -->
139 <A NAME="navbar_bottom"><!-- --></A>
140 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
141 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
142 <TR>
143 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
144 <A NAME="navbar_bottom_firstrow"><!-- --></A>
145 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
146 <TR ALIGN="center" VALIGN="top">
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
148 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Package</B></FONT>&nbsp;</TD>
149 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
150 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-use.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
155 </TR>
156 </TABLE>
157 </TD>
158 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
159 </EM>
160 </TD>
161 </TR>
162
163 <TR>
164 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
165 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-summary.html"><B>PREV PACKAGE</B></A>&nbsp;
166 &nbsp;NEXT PACKAGE</FONT></TD>
167 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
168 <A HREF="../../../../index.html?com/google/gson/stream/package-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
169 &nbsp;<A HREF="package-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
170 &nbsp;<SCRIPT type="text/javascript">
171 <!--
172 if(window==top) {
173 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
174 }
175 //-->
176 </SCRIPT>
177 <NOSCRIPT>
178 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
179 </NOSCRIPT>
180
181
182 </FONT></TD>
183 </TR>
184 </TABLE>
185 <A NAME="skip-navbar_bottom"></A>
186 <!-- ======== END OF BOTTOM NAVBAR ======= -->
187
188 <HR>
189 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
190 </BODY>
191 </HTML>
+0
-173
gson/docs/javadocs/com/google/gson/stream/package-tree.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 com.google.gson.stream Class Hierarchy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="com.google.gson.stream Class Hierarchy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-tree.html"><B>PREV</B></A>&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 Hierarchy For Package com.google.gson.stream
85 </H2>
86 </CENTER>
87 <DL>
88 <DT><B>Package Hierarchies:</B><DD><A HREF="../../../../overview-tree.html">All Packages</A></DL>
89 <HR>
90 <H2>
91 Class Hierarchy
92 </H2>
93 <UL>
94 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
95 <LI TYPE="circle">com.google.gson.stream.<A HREF="../../../../com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><B>JsonReader</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A>)
96 <LI TYPE="circle">com.google.gson.stream.<A HREF="../../../../com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>JsonWriter</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A>, java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Flushable.html?is-external=true" title="class or interface in java.io">Flushable</A>)
97 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang"><B>Throwable</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>)
98 <UL>
99 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang"><B>Exception</B></A><UL>
100 <LI TYPE="circle">java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io"><B>IOException</B></A><UL>
101 <LI TYPE="circle">com.google.gson.stream.<A HREF="../../../../com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><B>MalformedJsonException</B></A></UL>
102 </UL>
103 </UL>
104 </UL>
105 </UL>
106 <H2>
107 Enum Hierarchy
108 </H2>
109 <UL>
110 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
111 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang"><B>Enum</B></A>&lt;E&gt; (implements java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;T&gt;, java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>)
112 <UL>
113 <LI TYPE="circle">com.google.gson.stream.<A HREF="../../../../com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>JsonToken</B></A></UL>
114 </UL>
115 </UL>
116 <HR>
117
118
119 <!-- ======= START OF BOTTOM NAVBAR ====== -->
120 <A NAME="navbar_bottom"><!-- --></A>
121 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
122 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
123 <TR>
124 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
125 <A NAME="navbar_bottom_firstrow"><!-- --></A>
126 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
127 <TR ALIGN="center" VALIGN="top">
128 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
129 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
130 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
131 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
132 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
133 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
134 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
135 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
136 </TR>
137 </TABLE>
138 </TD>
139 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
140 </EM>
141 </TD>
142 </TR>
143
144 <TR>
145 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
146 &nbsp;<A HREF="../../../../com/google/gson/reflect/package-tree.html"><B>PREV</B></A>&nbsp;
147 &nbsp;NEXT</FONT></TD>
148 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
149 <A HREF="../../../../index.html?com/google/gson/stream/package-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
150 &nbsp;<A HREF="package-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
151 &nbsp;<SCRIPT type="text/javascript">
152 <!--
153 if(window==top) {
154 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
155 }
156 //-->
157 </SCRIPT>
158 <NOSCRIPT>
159 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
160 </NOSCRIPT>
161
162
163 </FONT></TD>
164 </TR>
165 </TABLE>
166 <A NAME="skip-navbar_bottom"></A>
167 <!-- ======== END OF BOTTOM NAVBAR ======= -->
168
169 <HR>
170 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
171 </BODY>
172 </HTML>
+0
-206
gson/docs/javadocs/com/google/gson/stream/package-use.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Uses of Package com.google.gson.stream (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Uses of Package com.google.gson.stream (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="../../../../index.html?com/google/gson/stream/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Uses of Package<br>com.google.gson.stream</B></H2>
85 </CENTER>
86
87 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
88 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
89 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
90 Packages that use <A HREF="../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A></FONT></TH>
91 </TR>
92 <TR BGCOLOR="white" CLASS="TableRowColor">
93 <TD><A HREF="#com.google.gson"><B>com.google.gson</B></A></TD>
94 <TD>This package provides the <A HREF="../../../../com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
95 vice-versa.&nbsp;</TD>
96 </TR>
97 <TR BGCOLOR="white" CLASS="TableRowColor">
98 <TD><A HREF="#com.google.gson.stream"><B>com.google.gson.stream</B></A></TD>
99 <TD>&nbsp;&nbsp;</TD>
100 </TR>
101 </TABLE>
102 &nbsp;
103 <P>
104 <A NAME="com.google.gson"><!-- --></A>
105 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
106 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
107 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
108 Classes in <A HREF="../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A> used by <A HREF="../../../../com/google/gson/package-summary.html">com.google.gson</A></FONT></TH>
109 </TR>
110 <TR BGCOLOR="white" CLASS="TableRowColor">
111 <TD><B><A HREF="../../../../com/google/gson/stream/class-use/JsonReader.html#com.google.gson"><B>JsonReader</B></A></B>
112
113 <BR>
114 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
115 encoded value as a stream of tokens.</TD>
116 </TR>
117 <TR BGCOLOR="white" CLASS="TableRowColor">
118 <TD><B><A HREF="../../../../com/google/gson/stream/class-use/JsonWriter.html#com.google.gson"><B>JsonWriter</B></A></B>
119
120 <BR>
121 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
122 encoded value to a stream, one token at a time.</TD>
123 </TR>
124 </TABLE>
125 &nbsp;
126 <P>
127 <A NAME="com.google.gson.stream"><!-- --></A>
128 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
129 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
130 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
131 Classes in <A HREF="../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A> used by <A HREF="../../../../com/google/gson/stream/package-summary.html">com.google.gson.stream</A></FONT></TH>
132 </TR>
133 <TR BGCOLOR="white" CLASS="TableRowColor">
134 <TD><B><A HREF="../../../../com/google/gson/stream/class-use/JsonToken.html#com.google.gson.stream"><B>JsonToken</B></A></B>
135
136 <BR>
137 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;A structure, name or value type in a JSON-encoded string.</TD>
138 </TR>
139 <TR BGCOLOR="white" CLASS="TableRowColor">
140 <TD><B><A HREF="../../../../com/google/gson/stream/class-use/JsonWriter.html#com.google.gson.stream"><B>JsonWriter</B></A></B>
141
142 <BR>
143 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
144 encoded value to a stream, one token at a time.</TD>
145 </TR>
146 </TABLE>
147 &nbsp;
148 <P>
149 <HR>
150
151
152 <!-- ======= START OF BOTTOM NAVBAR ====== -->
153 <A NAME="navbar_bottom"><!-- --></A>
154 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
155 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
156 <TR>
157 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
158 <A NAME="navbar_bottom_firstrow"><!-- --></A>
159 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
160 <TR ALIGN="center" VALIGN="top">
161 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
162 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
163 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
164 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT>&nbsp;</TD>
165 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
166 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
167 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
168 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
169 </TR>
170 </TABLE>
171 </TD>
172 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
173 </EM>
174 </TD>
175 </TR>
176
177 <TR>
178 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
179 &nbsp;PREV&nbsp;
180 &nbsp;NEXT</FONT></TD>
181 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
182 <A HREF="../../../../index.html?com/google/gson/stream/package-use.html" target="_top"><B>FRAMES</B></A> &nbsp;
183 &nbsp;<A HREF="package-use.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
184 &nbsp;<SCRIPT type="text/javascript">
185 <!--
186 if(window==top) {
187 document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
188 }
189 //-->
190 </SCRIPT>
191 <NOSCRIPT>
192 <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
193 </NOSCRIPT>
194
195
196 </FONT></TD>
197 </TR>
198 </TABLE>
199 <A NAME="skip-navbar_bottom"></A>
200 <!-- ======== END OF BOTTOM NAVBAR ======= -->
201
202 <HR>
203 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
204 </BODY>
205 </HTML>
+0
-147
gson/docs/javadocs/constant-values.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Constant Field Values (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Constant Field Values (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="index.html?constant-values.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="constant-values.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H1>
84 Constant Field Values</H1>
85 </CENTER>
86 <HR SIZE="4" NOSHADE>
87 <B>Contents</B><UL>
88 </UL>
89
90 <HR>
91
92
93 <!-- ======= START OF BOTTOM NAVBAR ====== -->
94 <A NAME="navbar_bottom"><!-- --></A>
95 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
96 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
97 <TR>
98 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
99 <A NAME="navbar_bottom_firstrow"><!-- --></A>
100 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
101 <TR ALIGN="center" VALIGN="top">
102 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
103 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
104 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
105 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
106 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
107 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
108 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
109 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
110 </TR>
111 </TABLE>
112 </TD>
113 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
114 </EM>
115 </TD>
116 </TR>
117
118 <TR>
119 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
120 &nbsp;PREV&nbsp;
121 &nbsp;NEXT</FONT></TD>
122 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
123 <A HREF="index.html?constant-values.html" target="_top"><B>FRAMES</B></A> &nbsp;
124 &nbsp;<A HREF="constant-values.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
125 &nbsp;<SCRIPT type="text/javascript">
126 <!--
127 if(window==top) {
128 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
129 }
130 //-->
131 </SCRIPT>
132 <NOSCRIPT>
133 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
134 </NOSCRIPT>
135
136
137 </FONT></TD>
138 </TR>
139 </TABLE>
140 <A NAME="skip-navbar_bottom"></A>
141 <!-- ======== END OF BOTTOM NAVBAR ======= -->
142
143 <HR>
144 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
145 </BODY>
146 </HTML>
+0
-190
gson/docs/javadocs/deprecated-list.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Deprecated List (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Deprecated List (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Deprecated</B></FONT>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="index.html?deprecated-list.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="deprecated-list.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 <B>Deprecated API</B></H2>
85 </CENTER>
86 <HR SIZE="4" NOSHADE>
87 <B>Contents</B><UL>
88 <LI><A HREF="#method">Deprecated Methods</A>
89 <LI><A HREF="#constructor">Deprecated Constructors</A>
90 </UL>
91
92 <A NAME="method"><!-- --></A>
93 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
94 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
95 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
96 <B>Deprecated Methods</B></FONT></TH>
97 </TR>
98 <TR BGCOLOR="white" CLASS="TableRowColor">
99 <TD><A HREF="com/google/gson/reflect/TypeToken.html#isAssignableFrom(java.lang.Class)">com.google.gson.reflect.TypeToken.isAssignableFrom(Class<?>)</A>
100 <BR>
101 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<I>this implementation may be inconsistent with javac for types
102 with wildcards.</I>&nbsp;</TD>
103 </TR>
104 <TR BGCOLOR="white" CLASS="TableRowColor">
105 <TD><A HREF="com/google/gson/reflect/TypeToken.html#isAssignableFrom(java.lang.reflect.Type)">com.google.gson.reflect.TypeToken.isAssignableFrom(Type)</A>
106 <BR>
107 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<I>this implementation may be inconsistent with javac for types
108 with wildcards.</I>&nbsp;</TD>
109 </TR>
110 <TR BGCOLOR="white" CLASS="TableRowColor">
111 <TD><A HREF="com/google/gson/reflect/TypeToken.html#isAssignableFrom(com.google.gson.reflect.TypeToken)">com.google.gson.reflect.TypeToken.isAssignableFrom(TypeToken<?>)</A>
112 <BR>
113 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<I>this implementation may be inconsistent with javac for types
114 with wildcards.</I>&nbsp;</TD>
115 </TR>
116 </TABLE>
117 &nbsp;
118 <P>
119 <A NAME="constructor"><!-- --></A>
120 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
121 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
122 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
123 <B>Deprecated Constructors</B></FONT></TH>
124 </TR>
125 <TR BGCOLOR="white" CLASS="TableRowColor">
126 <TD><A HREF="com/google/gson/JsonNull.html#JsonNull()">com.google.gson.JsonNull()</A>
127 <BR>
128 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
129 </TR>
130 </TABLE>
131 &nbsp;
132 <P>
133 <HR>
134
135
136 <!-- ======= START OF BOTTOM NAVBAR ====== -->
137 <A NAME="navbar_bottom"><!-- --></A>
138 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
139 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
140 <TR>
141 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
142 <A NAME="navbar_bottom_firstrow"><!-- --></A>
143 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
144 <TR ALIGN="center" VALIGN="top">
145 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
146 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
147 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
148 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
149 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
150 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Deprecated</B></FONT>&nbsp;</TD>
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
153 </TR>
154 </TABLE>
155 </TD>
156 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
157 </EM>
158 </TD>
159 </TR>
160
161 <TR>
162 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
163 &nbsp;PREV&nbsp;
164 &nbsp;NEXT</FONT></TD>
165 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
166 <A HREF="index.html?deprecated-list.html" target="_top"><B>FRAMES</B></A> &nbsp;
167 &nbsp;<A HREF="deprecated-list.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
168 &nbsp;<SCRIPT type="text/javascript">
169 <!--
170 if(window==top) {
171 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
172 }
173 //-->
174 </SCRIPT>
175 <NOSCRIPT>
176 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
177 </NOSCRIPT>
178
179
180 </FONT></TD>
181 </TR>
182 </TABLE>
183 <A NAME="skip-navbar_bottom"></A>
184 <!-- ======== END OF BOTTOM NAVBAR ======= -->
185
186 <HR>
187 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
188 </BODY>
189 </HTML>
+0
-224
gson/docs/javadocs/help-doc.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 API Help (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="API Help (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Help</B></FONT>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="index.html?help-doc.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="help-doc.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H1>
84 How This API Document Is Organized</H1>
85 </CENTER>
86 This API (Application Programming Interface) document has pages corresponding to the items in the navigation bar, described as follows.<H3>
87 Overview</H3>
88 <BLOCKQUOTE>
89
90 <P>
91 The <A HREF="overview-summary.html">Overview</A> page is the front page of this API document and provides a list of all packages with a summary for each. This page can also contain an overall description of the set of packages.</BLOCKQUOTE>
92 <H3>
93 Package</H3>
94 <BLOCKQUOTE>
95
96 <P>
97 Each package has a page that contains a list of its classes and interfaces, with a summary for each. This page can contain four categories:<UL>
98 <LI>Interfaces (italic)<LI>Classes<LI>Enums<LI>Exceptions<LI>Errors<LI>Annotation Types</UL>
99 </BLOCKQUOTE>
100 <H3>
101 Class/Interface</H3>
102 <BLOCKQUOTE>
103
104 <P>
105 Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a class/interface description, summary tables, and detailed member descriptions:<UL>
106 <LI>Class inheritance diagram<LI>Direct Subclasses<LI>All Known Subinterfaces<LI>All Known Implementing Classes<LI>Class/interface declaration<LI>Class/interface description
107 <P>
108 <LI>Nested Class Summary<LI>Field Summary<LI>Constructor Summary<LI>Method Summary
109 <P>
110 <LI>Field Detail<LI>Constructor Detail<LI>Method Detail</UL>
111 Each summary entry contains the first sentence from the detailed description for that item. The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.</BLOCKQUOTE>
112 </BLOCKQUOTE>
113 <H3>
114 Annotation Type</H3>
115 <BLOCKQUOTE>
116
117 <P>
118 Each annotation type has its own separate page with the following sections:<UL>
119 <LI>Annotation Type declaration<LI>Annotation Type description<LI>Required Element Summary<LI>Optional Element Summary<LI>Element Detail</UL>
120 </BLOCKQUOTE>
121 </BLOCKQUOTE>
122 <H3>
123 Enum</H3>
124 <BLOCKQUOTE>
125
126 <P>
127 Each enum has its own separate page with the following sections:<UL>
128 <LI>Enum declaration<LI>Enum description<LI>Enum Constant Summary<LI>Enum Constant Detail</UL>
129 </BLOCKQUOTE>
130 <H3>
131 Use</H3>
132 <BLOCKQUOTE>
133 Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the "Use" link in the navigation bar.</BLOCKQUOTE>
134 <H3>
135 Tree (Class Hierarchy)</H3>
136 <BLOCKQUOTE>
137 There is a <A HREF="overview-tree.html">Class Hierarchy</A> page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. The classes are organized by inheritance structure starting with <code>java.lang.Object</code>. The interfaces do not inherit from <code>java.lang.Object</code>.<UL>
138 <LI>When viewing the Overview page, clicking on "Tree" displays the hierarchy for all packages.<LI>When viewing a particular package, class or interface page, clicking "Tree" displays the hierarchy for only that package.</UL>
139 </BLOCKQUOTE>
140 <H3>
141 Deprecated API</H3>
142 <BLOCKQUOTE>
143 The <A HREF="deprecated-list.html">Deprecated API</A> page lists all of the API that have been deprecated. A deprecated API is not recommended for use, generally due to improvements, and a replacement API is usually given. Deprecated APIs may be removed in future implementations.</BLOCKQUOTE>
144 <H3>
145 Index</H3>
146 <BLOCKQUOTE>
147 The <A HREF="index-all.html">Index</A> contains an alphabetic list of all classes, interfaces, constructors, methods, and fields.</BLOCKQUOTE>
148 <H3>
149 Prev/Next</H3>
150 These links take you to the next or previous class, interface, package, or related page.<H3>
151 Frames/No Frames</H3>
152 These links show and hide the HTML frames. All pages are available with or without frames.
153 <P>
154 <H3>
155 Serialized Form</H3>
156 Each serializable or externalizable class has a description of its serialization fields and methods. This information is of interest to re-implementors, not to developers using the API. While there is no link in the navigation bar, you can get to this information by going to any serialized class and clicking "Serialized Form" in the "See also" section of the class description.
157 <P>
158 <H3>
159 Constant Field Values</H3>
160 The <a href="constant-values.html">Constant Field Values</a> page lists the static final fields and their values.
161 <P>
162 <FONT SIZE="-1">
163 <EM>
164 This help file applies to API documentation generated using the standard doclet.</EM>
165 </FONT>
166 <BR>
167 <HR>
168
169
170 <!-- ======= START OF BOTTOM NAVBAR ====== -->
171 <A NAME="navbar_bottom"><!-- --></A>
172 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
173 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
174 <TR>
175 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
176 <A NAME="navbar_bottom_firstrow"><!-- --></A>
177 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
178 <TR ALIGN="center" VALIGN="top">
179 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
180 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
181 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
182 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
183 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
184 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
185 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
186 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Help</B></FONT>&nbsp;</TD>
187 </TR>
188 </TABLE>
189 </TD>
190 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
191 </EM>
192 </TD>
193 </TR>
194
195 <TR>
196 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
197 &nbsp;PREV&nbsp;
198 &nbsp;NEXT</FONT></TD>
199 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
200 <A HREF="index.html?help-doc.html" target="_top"><B>FRAMES</B></A> &nbsp;
201 &nbsp;<A HREF="help-doc.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
202 &nbsp;<SCRIPT type="text/javascript">
203 <!--
204 if(window==top) {
205 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
206 }
207 //-->
208 </SCRIPT>
209 <NOSCRIPT>
210 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
211 </NOSCRIPT>
212
213
214 </FONT></TD>
215 </TR>
216 </TABLE>
217 <A NAME="skip-navbar_bottom"></A>
218 <!-- ======== END OF BOTTOM NAVBAR ======= -->
219
220 <HR>
221 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
222 </BODY>
223 </HTML>
+0
-1030
gson/docs/javadocs/index-all.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Index (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="./stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Index (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Index</B></FONT>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="./index.html?index-all.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="index-all.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="./allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="./allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <A HREF="#_A_">A</A> <A HREF="#_B_">B</A> <A HREF="#_C_">C</A> <A HREF="#_D_">D</A> <A HREF="#_E_">E</A> <A HREF="#_F_">F</A> <A HREF="#_G_">G</A> <A HREF="#_H_">H</A> <A HREF="#_I_">I</A> <A HREF="#_J_">J</A> <A HREF="#_L_">L</A> <A HREF="#_M_">M</A> <A HREF="#_N_">N</A> <A HREF="#_P_">P</A> <A HREF="#_R_">R</A> <A HREF="#_S_">S</A> <A HREF="#_T_">T</A> <A HREF="#_U_">U</A> <A HREF="#_V_">V</A> <A HREF="#_W_">W</A> <HR>
82 <A NAME="_A_"><!-- --></A><H2>
83 <B>A</B></H2>
84 <DL>
85 <DT><A HREF="./com/google/gson/JsonArray.html#add(com.google.gson.JsonElement)"><B>add(JsonElement)</B></A> -
86 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
87 <DD>Adds the specified element to self.
88 <DT><A HREF="./com/google/gson/JsonObject.html#add(java.lang.String, com.google.gson.JsonElement)"><B>add(String, JsonElement)</B></A> -
89 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
90 <DD>Adds a member, which is a name-value pair, to self.
91 <DT><A HREF="./com/google/gson/JsonArray.html#addAll(com.google.gson.JsonArray)"><B>addAll(JsonArray)</B></A> -
92 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
93 <DD>Adds all the elements of the specified array to self.
94 <DT><A HREF="./com/google/gson/GsonBuilder.html#addDeserializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><B>addDeserializationExclusionStrategy(ExclusionStrategy)</B></A> -
95 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
96 <DD>Configures Gson to apply the passed in exclusion strategy during deserialization.
97 <DT><A HREF="./com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.String)"><B>addProperty(String, String)</B></A> -
98 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
99 <DD>Convenience method to add a primitive member.
100 <DT><A HREF="./com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.Number)"><B>addProperty(String, Number)</B></A> -
101 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
102 <DD>Convenience method to add a primitive member.
103 <DT><A HREF="./com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.Boolean)"><B>addProperty(String, Boolean)</B></A> -
104 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
105 <DD>Convenience method to add a boolean member.
106 <DT><A HREF="./com/google/gson/JsonObject.html#addProperty(java.lang.String, java.lang.Character)"><B>addProperty(String, Character)</B></A> -
107 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
108 <DD>Convenience method to add a char member.
109 <DT><A HREF="./com/google/gson/GsonBuilder.html#addSerializationExclusionStrategy(com.google.gson.ExclusionStrategy)"><B>addSerializationExclusionStrategy(ExclusionStrategy)</B></A> -
110 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
111 <DD>Configures Gson to apply the passed in exclusion strategy during serialization.
112 </DL>
113 <HR>
114 <A NAME="_B_"><!-- --></A><H2>
115 <B>B</B></H2>
116 <DL>
117 <DT><A HREF="./com/google/gson/stream/JsonReader.html#beginArray()"><B>beginArray()</B></A> -
118 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
119 <DD>Consumes the next token from the JSON stream and asserts that it is the
120 beginning of a new array.
121 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#beginArray()"><B>beginArray()</B></A> -
122 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
123 <DD>Begins encoding a new array.
124 <DT><A HREF="./com/google/gson/stream/JsonReader.html#beginObject()"><B>beginObject()</B></A> -
125 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
126 <DD>Consumes the next token from the JSON stream and asserts that it is the
127 beginning of a new object.
128 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#beginObject()"><B>beginObject()</B></A> -
129 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
130 <DD>Begins encoding a new object.
131 </DL>
132 <HR>
133 <A NAME="_C_"><!-- --></A><H2>
134 <B>C</B></H2>
135 <DL>
136 <DT><A HREF="./com/google/gson/stream/JsonReader.html#close()"><B>close()</B></A> -
137 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
138 <DD>Closes this JSON reader and the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Reader.html?is-external=true" title="class or interface in java.io"><CODE>Reader</CODE></A>.
139 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#close()"><B>close()</B></A> -
140 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
141 <DD>Flushes and closes this writer and the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>.
142 <DT><A HREF="./com/google/gson/package-summary.html"><B>com.google.gson</B></A> - package com.google.gson<DD>This package provides the <A HREF="./com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
143 vice-versa.<DT><A HREF="./com/google/gson/annotations/package-summary.html"><B>com.google.gson.annotations</B></A> - package com.google.gson.annotations<DD>This package provides annotations that can be used with <A HREF="./com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A>.<DT><A HREF="./com/google/gson/reflect/package-summary.html"><B>com.google.gson.reflect</B></A> - package com.google.gson.reflect<DD>This package provides utility classes for finding type information for generic types.<DT><A HREF="./com/google/gson/stream/package-summary.html"><B>com.google.gson.stream</B></A> - package com.google.gson.stream<DD>&nbsp;<DT><A HREF="./com/google/gson/JsonArray.html#contains(com.google.gson.JsonElement)"><B>contains(JsonElement)</B></A> -
144 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
145 <DD>Returns true if this array contains the specified element.
146 <DT><A HREF="./com/google/gson/GsonBuilder.html#create()"><B>create()</B></A> -
147 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
148 <DD>Creates a <A HREF="./com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance based on the current configuration.
149 <DT><A HREF="./com/google/gson/TypeAdapterFactory.html#create(com.google.gson.Gson, com.google.gson.reflect.TypeToken)"><B>create(Gson, TypeToken&lt;T&gt;)</B></A> -
150 Method in interface com.google.gson.<A HREF="./com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson">TypeAdapterFactory</A>
151 <DD>Returns a type adapter for <code>type</code>, or null if this factory doesn't
152 support <code>type</code>.
153 <DT><A HREF="./com/google/gson/InstanceCreator.html#createInstance(java.lang.reflect.Type)"><B>createInstance(Type)</B></A> -
154 Method in interface com.google.gson.<A HREF="./com/google/gson/InstanceCreator.html" title="interface in com.google.gson">InstanceCreator</A>
155 <DD>Gson invokes this call-back method during deserialization to create an instance of the
156 specified type.
157 </DL>
158 <HR>
159 <A NAME="_D_"><!-- --></A><H2>
160 <B>D</B></H2>
161 <DL>
162 <DT><A HREF="./com/google/gson/JsonDeserializationContext.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type)"><B>deserialize(JsonElement, Type)</B></A> -
163 Method in interface com.google.gson.<A HREF="./com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson">JsonDeserializationContext</A>
164 <DD>Invokes default deserialization on the specified object.
165 <DT><A HREF="./com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><B>deserialize(JsonElement, Type, JsonDeserializationContext)</B></A> -
166 Method in interface com.google.gson.<A HREF="./com/google/gson/JsonDeserializer.html" title="interface in com.google.gson">JsonDeserializer</A>
167 <DD>Gson invokes this call-back method during deserialization when it encounters a field of the
168 specified type.
169 <DT><A HREF="./com/google/gson/GsonBuilder.html#disableHtmlEscaping()"><B>disableHtmlEscaping()</B></A> -
170 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
171 <DD>By default, Gson escapes HTML characters such as &lt; &gt; etc.
172 <DT><A HREF="./com/google/gson/GsonBuilder.html#disableInnerClassSerialization()"><B>disableInnerClassSerialization()</B></A> -
173 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
174 <DD>Configures Gson to exclude inner classes during serialization.
175 </DL>
176 <HR>
177 <A NAME="_E_"><!-- --></A><H2>
178 <B>E</B></H2>
179 <DL>
180 <DT><A HREF="./com/google/gson/GsonBuilder.html#enableComplexMapKeySerialization()"><B>enableComplexMapKeySerialization()</B></A> -
181 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
182 <DD>Enabling this feature will only change the serialized form if the map key is
183 a complex type (i.e.
184 <DT><A HREF="./com/google/gson/stream/JsonReader.html#endArray()"><B>endArray()</B></A> -
185 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
186 <DD>Consumes the next token from the JSON stream and asserts that it is the
187 end of the current array.
188 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#endArray()"><B>endArray()</B></A> -
189 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
190 <DD>Ends encoding the current array.
191 <DT><A HREF="./com/google/gson/stream/JsonReader.html#endObject()"><B>endObject()</B></A> -
192 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
193 <DD>Consumes the next token from the JSON stream and asserts that it is the
194 end of the current object.
195 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#endObject()"><B>endObject()</B></A> -
196 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
197 <DD>Ends encoding the current object.
198 <DT><A HREF="./com/google/gson/JsonObject.html#entrySet()"><B>entrySet()</B></A> -
199 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
200 <DD>Returns a set of members of this object.
201 <DT><A HREF="./com/google/gson/JsonArray.html#equals(java.lang.Object)"><B>equals(Object)</B></A> -
202 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
203 <DD>&nbsp;
204 <DT><A HREF="./com/google/gson/JsonNull.html#equals(java.lang.Object)"><B>equals(Object)</B></A> -
205 Method in class com.google.gson.<A HREF="./com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A>
206 <DD>All instances of JsonNull are the same
207 <DT><A HREF="./com/google/gson/JsonObject.html#equals(java.lang.Object)"><B>equals(Object)</B></A> -
208 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
209 <DD>&nbsp;
210 <DT><A HREF="./com/google/gson/JsonPrimitive.html#equals(java.lang.Object)"><B>equals(Object)</B></A> -
211 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
212 <DD>&nbsp;
213 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#equals(java.lang.Object)"><B>equals(Object)</B></A> -
214 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
215 <DD>&nbsp;
216 <DT><A HREF="./com/google/gson/GsonBuilder.html#excludeFieldsWithModifiers(int...)"><B>excludeFieldsWithModifiers(int...)</B></A> -
217 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
218 <DD>Configures Gson to excludes all class fields that have the specified modifiers.
219 <DT><A HREF="./com/google/gson/GsonBuilder.html#excludeFieldsWithoutExposeAnnotation()"><B>excludeFieldsWithoutExposeAnnotation()</B></A> -
220 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
221 <DD>Configures Gson to exclude all fields from consideration for serialization or deserialization
222 that do not have the <A HREF="./com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><CODE>Expose</CODE></A> annotation.
223 <DT><A HREF="./com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><B>ExclusionStrategy</B></A> - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A strategy (or policy) definition that is used to decide whether or not a field or top-level
224 class should be serialized or deserialized as part of the JSON output/input.<DT><A HREF="./com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><B>Expose</B></A> - Annotation Type in <A HREF="./com/google/gson/annotations/package-summary.html">com.google.gson.annotations</A><DD>An annotation that indicates this member should be exposed for JSON
225 serialization or deserialization.</DL>
226 <HR>
227 <A NAME="_F_"><!-- --></A><H2>
228 <B>F</B></H2>
229 <DL>
230 <DT><A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>FieldAttributes</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A data object that stores attributes of a field.<DT><A HREF="./com/google/gson/FieldAttributes.html#FieldAttributes(java.lang.reflect.Field)"><B>FieldAttributes(Field)</B></A> -
231 Constructor for class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
232 <DD>Constructs a Field Attributes object from the <code>f</code>.
233 <DT><A HREF="./com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>FieldNamingPolicy</B></A> - Enum in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>An enumeration that defines a few standard naming conventions for JSON field names.<DT><A HREF="./com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>FieldNamingStrategy</B></A> - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A mechanism for providing custom field naming in Gson.<DT><A HREF="./com/google/gson/stream/JsonWriter.html#flush()"><B>flush()</B></A> -
234 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
235 <DD>Ensures all buffered data is written to the underlying <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Writer.html?is-external=true" title="class or interface in java.io"><CODE>Writer</CODE></A>
236 and flushes that writer.
237 <DT><A HREF="./com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.Class)"><B>fromJson(String, Class&lt;T&gt;)</B></A> -
238 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
239 <DD>This method deserializes the specified Json into an object of the specified class.
240 <DT><A HREF="./com/google/gson/Gson.html#fromJson(java.lang.String, java.lang.reflect.Type)"><B>fromJson(String, Type)</B></A> -
241 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
242 <DD>This method deserializes the specified Json into an object of the specified type.
243 <DT><A HREF="./com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.Class)"><B>fromJson(Reader, Class&lt;T&gt;)</B></A> -
244 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
245 <DD>This method deserializes the Json read from the specified reader into an object of the
246 specified class.
247 <DT><A HREF="./com/google/gson/Gson.html#fromJson(java.io.Reader, java.lang.reflect.Type)"><B>fromJson(Reader, Type)</B></A> -
248 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
249 <DD>This method deserializes the Json read from the specified reader into an object of the
250 specified type.
251 <DT><A HREF="./com/google/gson/Gson.html#fromJson(com.google.gson.stream.JsonReader, java.lang.reflect.Type)"><B>fromJson(JsonReader, Type)</B></A> -
252 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
253 <DD>Reads the next JSON value from <code>reader</code> and convert it to an object
254 of type <code>typeOfT</code>.
255 <DT><A HREF="./com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.Class)"><B>fromJson(JsonElement, Class&lt;T&gt;)</B></A> -
256 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
257 <DD>This method deserializes the Json read from the specified parse tree into an object of the
258 specified type.
259 <DT><A HREF="./com/google/gson/Gson.html#fromJson(com.google.gson.JsonElement, java.lang.reflect.Type)"><B>fromJson(JsonElement, Type)</B></A> -
260 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
261 <DD>This method deserializes the Json read from the specified parse tree into an object of the
262 specified type.
263 <DT><A HREF="./com/google/gson/TypeAdapter.html#fromJson(java.io.Reader)"><B>fromJson(Reader)</B></A> -
264 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
265 <DD>Converts the JSON document in <code>in</code> to a Java object.
266 <DT><A HREF="./com/google/gson/TypeAdapter.html#fromJson(java.lang.String)"><B>fromJson(String)</B></A> -
267 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
268 <DD>Converts the JSON document in <code>json</code> to a Java object.
269 <DT><A HREF="./com/google/gson/TypeAdapter.html#fromJsonTree(com.google.gson.JsonElement)"><B>fromJsonTree(JsonElement)</B></A> -
270 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
271 <DD>Converts <code>jsonTree</code> to a Java object.
272 </DL>
273 <HR>
274 <A NAME="_G_"><!-- --></A><H2>
275 <B>G</B></H2>
276 <DL>
277 <DT><A HREF="./com/google/gson/GsonBuilder.html#generateNonExecutableJson()"><B>generateNonExecutableJson()</B></A> -
278 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
279 <DD>Makes the output JSON non-executable in Javascript by prefixing the generated JSON with some
280 special text.
281 <DT><A HREF="./com/google/gson/JsonArray.html#get(int)"><B>get(int)</B></A> -
282 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
283 <DD>Returns the ith element of the array.
284 <DT><A HREF="./com/google/gson/JsonObject.html#get(java.lang.String)"><B>get(String)</B></A> -
285 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
286 <DD>Returns the member with the specified name.
287 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#get(java.lang.reflect.Type)"><B>get(Type)</B></A> -
288 Static method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
289 <DD>Gets type literal for the given <code>Type</code> instance.
290 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#get(java.lang.Class)"><B>get(Class&lt;T&gt;)</B></A> -
291 Static method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
292 <DD>Gets type literal for the given <code>Class</code> instance.
293 <DT><A HREF="./com/google/gson/Gson.html#getAdapter(com.google.gson.reflect.TypeToken)"><B>getAdapter(TypeToken&lt;T&gt;)</B></A> -
294 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
295 <DD>Returns the type adapter for <code></code> type.
296 <DT><A HREF="./com/google/gson/Gson.html#getAdapter(java.lang.Class)"><B>getAdapter(Class&lt;T&gt;)</B></A> -
297 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
298 <DD>Returns the type adapter for <code></code> type.
299 <DT><A HREF="./com/google/gson/FieldAttributes.html#getAnnotation(java.lang.Class)"><B>getAnnotation(Class&lt;T&gt;)</B></A> -
300 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
301 <DD>Return the <code>T</code> annotation object from this field if it exist; otherwise returns
302 <code>null</code>.
303 <DT><A HREF="./com/google/gson/FieldAttributes.html#getAnnotations()"><B>getAnnotations()</B></A> -
304 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
305 <DD>Return the annotations that are present on this field.
306 <DT><A HREF="./com/google/gson/JsonArray.html#getAsBigDecimal()"><B>getAsBigDecimal()</B></A> -
307 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
308 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A> if it contains a single element.
309 <DT><A HREF="./com/google/gson/JsonElement.html#getAsBigDecimal()"><B>getAsBigDecimal()</B></A> -
310 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
311 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
312 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsBigDecimal()"><B>getAsBigDecimal()</B></A> -
313 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
314 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigDecimal.html?is-external=true" title="class or interface in java.math"><CODE>BigDecimal</CODE></A>.
315 <DT><A HREF="./com/google/gson/JsonArray.html#getAsBigInteger()"><B>getAsBigInteger()</B></A> -
316 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
317 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A> if it contains a single element.
318 <DT><A HREF="./com/google/gson/JsonElement.html#getAsBigInteger()"><B>getAsBigInteger()</B></A> -
319 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
320 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
321 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsBigInteger()"><B>getAsBigInteger()</B></A> -
322 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
323 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/math/BigInteger.html?is-external=true" title="class or interface in java.math"><CODE>BigInteger</CODE></A>.
324 <DT><A HREF="./com/google/gson/JsonArray.html#getAsBoolean()"><B>getAsBoolean()</B></A> -
325 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
326 <DD>convenience method to get this array as a boolean if it contains a single element.
327 <DT><A HREF="./com/google/gson/JsonElement.html#getAsBoolean()"><B>getAsBoolean()</B></A> -
328 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
329 <DD>convenience method to get this element as a boolean value.
330 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsBoolean()"><B>getAsBoolean()</B></A> -
331 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
332 <DD>convenience method to get this element as a boolean value.
333 <DT><A HREF="./com/google/gson/JsonArray.html#getAsByte()"><B>getAsByte()</B></A> -
334 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
335 <DD>&nbsp;
336 <DT><A HREF="./com/google/gson/JsonElement.html#getAsByte()"><B>getAsByte()</B></A> -
337 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
338 <DD>convenience method to get this element as a primitive byte value.
339 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsByte()"><B>getAsByte()</B></A> -
340 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
341 <DD>&nbsp;
342 <DT><A HREF="./com/google/gson/JsonArray.html#getAsCharacter()"><B>getAsCharacter()</B></A> -
343 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
344 <DD>&nbsp;
345 <DT><A HREF="./com/google/gson/JsonElement.html#getAsCharacter()"><B>getAsCharacter()</B></A> -
346 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
347 <DD>convenience method to get this element as a primitive character value.
348 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsCharacter()"><B>getAsCharacter()</B></A> -
349 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
350 <DD>&nbsp;
351 <DT><A HREF="./com/google/gson/JsonArray.html#getAsDouble()"><B>getAsDouble()</B></A> -
352 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
353 <DD>convenience method to get this array as a double if it contains a single element.
354 <DT><A HREF="./com/google/gson/JsonElement.html#getAsDouble()"><B>getAsDouble()</B></A> -
355 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
356 <DD>convenience method to get this element as a primitive double value.
357 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsDouble()"><B>getAsDouble()</B></A> -
358 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
359 <DD>convenience method to get this element as a primitive double.
360 <DT><A HREF="./com/google/gson/JsonArray.html#getAsFloat()"><B>getAsFloat()</B></A> -
361 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
362 <DD>convenience method to get this array as a float if it contains a single element.
363 <DT><A HREF="./com/google/gson/JsonElement.html#getAsFloat()"><B>getAsFloat()</B></A> -
364 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
365 <DD>convenience method to get this element as a primitive float value.
366 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsFloat()"><B>getAsFloat()</B></A> -
367 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
368 <DD>convenience method to get this element as a float.
369 <DT><A HREF="./com/google/gson/JsonArray.html#getAsInt()"><B>getAsInt()</B></A> -
370 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
371 <DD>convenience method to get this array as an integer if it contains a single element.
372 <DT><A HREF="./com/google/gson/JsonElement.html#getAsInt()"><B>getAsInt()</B></A> -
373 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
374 <DD>convenience method to get this element as a primitive integer value.
375 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsInt()"><B>getAsInt()</B></A> -
376 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
377 <DD>convenience method to get this element as a primitive integer.
378 <DT><A HREF="./com/google/gson/JsonElement.html#getAsJsonArray()"><B>getAsJsonArray()</B></A> -
379 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
380 <DD>convenience method to get this element as a <A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson"><CODE>JsonArray</CODE></A>.
381 <DT><A HREF="./com/google/gson/JsonObject.html#getAsJsonArray(java.lang.String)"><B>getAsJsonArray(String)</B></A> -
382 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
383 <DD>Convenience method to get the specified member as a JsonArray.
384 <DT><A HREF="./com/google/gson/JsonElement.html#getAsJsonNull()"><B>getAsJsonNull()</B></A> -
385 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
386 <DD>convenience method to get this element as a <A HREF="./com/google/gson/JsonNull.html" title="class in com.google.gson"><CODE>JsonNull</CODE></A>.
387 <DT><A HREF="./com/google/gson/JsonElement.html#getAsJsonObject()"><B>getAsJsonObject()</B></A> -
388 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
389 <DD>convenience method to get this element as a <A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.
390 <DT><A HREF="./com/google/gson/JsonObject.html#getAsJsonObject(java.lang.String)"><B>getAsJsonObject(String)</B></A> -
391 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
392 <DD>Convenience method to get the specified member as a JsonObject.
393 <DT><A HREF="./com/google/gson/JsonElement.html#getAsJsonPrimitive()"><B>getAsJsonPrimitive()</B></A> -
394 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
395 <DD>convenience method to get this element as a <A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><CODE>JsonPrimitive</CODE></A>.
396 <DT><A HREF="./com/google/gson/JsonObject.html#getAsJsonPrimitive(java.lang.String)"><B>getAsJsonPrimitive(String)</B></A> -
397 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
398 <DD>Convenience method to get the specified member as a JsonPrimitive element.
399 <DT><A HREF="./com/google/gson/JsonArray.html#getAsLong()"><B>getAsLong()</B></A> -
400 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
401 <DD>convenience method to get this array as a long if it contains a single element.
402 <DT><A HREF="./com/google/gson/JsonElement.html#getAsLong()"><B>getAsLong()</B></A> -
403 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
404 <DD>convenience method to get this element as a primitive long value.
405 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsLong()"><B>getAsLong()</B></A> -
406 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
407 <DD>convenience method to get this element as a primitive long.
408 <DT><A HREF="./com/google/gson/JsonArray.html#getAsNumber()"><B>getAsNumber()</B></A> -
409 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
410 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A> if it contains a single element.
411 <DT><A HREF="./com/google/gson/JsonElement.html#getAsNumber()"><B>getAsNumber()</B></A> -
412 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
413 <DD>convenience method to get this element as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.
414 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsNumber()"><B>getAsNumber()</B></A> -
415 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
416 <DD>convenience method to get this element as a Number.
417 <DT><A HREF="./com/google/gson/JsonArray.html#getAsShort()"><B>getAsShort()</B></A> -
418 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
419 <DD>convenience method to get this array as a primitive short if it contains a single element.
420 <DT><A HREF="./com/google/gson/JsonElement.html#getAsShort()"><B>getAsShort()</B></A> -
421 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
422 <DD>convenience method to get this element as a primitive short value.
423 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsShort()"><B>getAsShort()</B></A> -
424 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
425 <DD>convenience method to get this element as a primitive short.
426 <DT><A HREF="./com/google/gson/JsonArray.html#getAsString()"><B>getAsString()</B></A> -
427 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
428 <DD>convenience method to get this array as a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang"><CODE>String</CODE></A> if it contains a single element.
429 <DT><A HREF="./com/google/gson/JsonElement.html#getAsString()"><B>getAsString()</B></A> -
430 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
431 <DD>convenience method to get this element as a string value.
432 <DT><A HREF="./com/google/gson/JsonPrimitive.html#getAsString()"><B>getAsString()</B></A> -
433 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
434 <DD>convenience method to get this element as a String.
435 <DT><A HREF="./com/google/gson/FieldAttributes.html#getDeclaredClass()"><B>getDeclaredClass()</B></A> -
436 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
437 <DD>Returns the <code>Class</code> object that was declared for this field.
438 <DT><A HREF="./com/google/gson/FieldAttributes.html#getDeclaredType()"><B>getDeclaredType()</B></A> -
439 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
440 <DD>For example, assume the following class definition:
441 <pre class="code">
442 public class Foo {
443 private String bar;
444 private List&lt;String&gt; red;
445 }
446
447 Type listParmeterizedType = new TypeToken&lt;List&lt;String&gt;&gt;() {}.getType();
448 <DT><A HREF="./com/google/gson/FieldAttributes.html#getDeclaringClass()"><B>getDeclaringClass()</B></A> -
449 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
450 <DD>&nbsp;
451 <DT><A HREF="./com/google/gson/Gson.html#getDelegateAdapter(com.google.gson.TypeAdapterFactory, com.google.gson.reflect.TypeToken)"><B>getDelegateAdapter(TypeAdapterFactory, TypeToken&lt;T&gt;)</B></A> -
452 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
453 <DD>This method is used to get an alternate type adapter for the specified type.
454 <DT><A HREF="./com/google/gson/FieldAttributes.html#getName()"><B>getName()</B></A> -
455 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
456 <DD>&nbsp;
457 <DT><A HREF="./com/google/gson/stream/JsonReader.html#getPath()"><B>getPath()</B></A> -
458 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
459 <DD>Returns a <a href="http://goessner.net/articles/JsonPath/">JsonPath</a> to
460 the current location in the JSON value.
461 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#getRawType()"><B>getRawType()</B></A> -
462 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
463 <DD>Returns the raw (non-generic) type for this type.
464 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#getSerializeNulls()"><B>getSerializeNulls()</B></A> -
465 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
466 <DD>Returns true if object members are serialized when their value is null.
467 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#getType()"><B>getType()</B></A> -
468 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
469 <DD>Gets underlying <code>Type</code> instance.
470 <DT><A HREF="./com/google/gson/Gson.html" title="class in com.google.gson"><B>Gson</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>This is the main class for using Gson.<DT><A HREF="./com/google/gson/Gson.html#Gson()"><B>Gson()</B></A> -
471 Constructor for class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
472 <DD>Constructs a Gson object with default configuration.
473 <DT><A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>GsonBuilder</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Use this builder to construct a <A HREF="./com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> instance when you need to set configuration
474 options other than the default.<DT><A HREF="./com/google/gson/GsonBuilder.html#GsonBuilder()"><B>GsonBuilder()</B></A> -
475 Constructor for class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
476 <DD>Creates a GsonBuilder instance that can be used to build Gson with various configuration
477 settings.
478 </DL>
479 <HR>
480 <A NAME="_H_"><!-- --></A><H2>
481 <B>H</B></H2>
482 <DL>
483 <DT><A HREF="./com/google/gson/JsonObject.html#has(java.lang.String)"><B>has(String)</B></A> -
484 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
485 <DD>Convenience method to check if a member with the specified name is present in this object.
486 <DT><A HREF="./com/google/gson/JsonArray.html#hashCode()"><B>hashCode()</B></A> -
487 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
488 <DD>&nbsp;
489 <DT><A HREF="./com/google/gson/JsonNull.html#hashCode()"><B>hashCode()</B></A> -
490 Method in class com.google.gson.<A HREF="./com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A>
491 <DD>All instances of JsonNull have the same hash code since they are indistinguishable
492 <DT><A HREF="./com/google/gson/JsonObject.html#hashCode()"><B>hashCode()</B></A> -
493 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
494 <DD>&nbsp;
495 <DT><A HREF="./com/google/gson/JsonPrimitive.html#hashCode()"><B>hashCode()</B></A> -
496 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
497 <DD>&nbsp;
498 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#hashCode()"><B>hashCode()</B></A> -
499 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
500 <DD>&nbsp;
501 <DT><A HREF="./com/google/gson/FieldAttributes.html#hasModifier(int)"><B>hasModifier(int)</B></A> -
502 Method in class com.google.gson.<A HREF="./com/google/gson/FieldAttributes.html" title="class in com.google.gson">FieldAttributes</A>
503 <DD>Returns <code>true</code> if the field is defined with the <code>modifier</code>.
504 <DT><A HREF="./com/google/gson/JsonStreamParser.html#hasNext()"><B>hasNext()</B></A> -
505 Method in class com.google.gson.<A HREF="./com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A>
506 <DD>Returns true if a <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> is available on the input for consumption
507 <DT><A HREF="./com/google/gson/stream/JsonReader.html#hasNext()"><B>hasNext()</B></A> -
508 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
509 <DD>Returns true if the current array or object has another element.
510 </DL>
511 <HR>
512 <A NAME="_I_"><!-- --></A><H2>
513 <B>I</B></H2>
514 <DL>
515 <DT><A HREF="./com/google/gson/JsonNull.html#INSTANCE"><B>INSTANCE</B></A> -
516 Static variable in class com.google.gson.<A HREF="./com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A>
517 <DD>singleton for JsonNull
518 <DT><A HREF="./com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>InstanceCreator</B></A>&lt;<A HREF="./com/google/gson/InstanceCreator.html" title="type parameter in InstanceCreator">T</A>&gt; - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>This interface is implemented to create instances of a class that does not define a no-args
519 constructor.<DT><A HREF="./com/google/gson/reflect/TypeToken.html#isAssignableFrom(java.lang.Class)"><B>isAssignableFrom(Class&lt;?&gt;)</B></A> -
520 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
521 <DD><B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
522 with wildcards.</I>
523 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#isAssignableFrom(java.lang.reflect.Type)"><B>isAssignableFrom(Type)</B></A> -
524 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
525 <DD><B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
526 with wildcards.</I>
527 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#isAssignableFrom(com.google.gson.reflect.TypeToken)"><B>isAssignableFrom(TypeToken&lt;?&gt;)</B></A> -
528 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
529 <DD><B>Deprecated.</B>&nbsp;<I>this implementation may be inconsistent with javac for types
530 with wildcards.</I>
531 <DT><A HREF="./com/google/gson/JsonPrimitive.html#isBoolean()"><B>isBoolean()</B></A> -
532 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
533 <DD>Check whether this primitive contains a boolean value.
534 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#isHtmlSafe()"><B>isHtmlSafe()</B></A> -
535 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
536 <DD>Returns true if this writer writes JSON that's safe for inclusion in HTML
537 and XML documents.
538 <DT><A HREF="./com/google/gson/JsonElement.html#isJsonArray()"><B>isJsonArray()</B></A> -
539 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
540 <DD>provides check for verifying if this element is an array or not.
541 <DT><A HREF="./com/google/gson/JsonElement.html#isJsonNull()"><B>isJsonNull()</B></A> -
542 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
543 <DD>provides check for verifying if this element represents a null value or not.
544 <DT><A HREF="./com/google/gson/JsonElement.html#isJsonObject()"><B>isJsonObject()</B></A> -
545 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
546 <DD>provides check for verifying if this element is a Json object or not.
547 <DT><A HREF="./com/google/gson/JsonElement.html#isJsonPrimitive()"><B>isJsonPrimitive()</B></A> -
548 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
549 <DD>provides check for verifying if this element is a primitive or not.
550 <DT><A HREF="./com/google/gson/stream/JsonReader.html#isLenient()"><B>isLenient()</B></A> -
551 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
552 <DD>Returns true if this parser is liberal in what it accepts.
553 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#isLenient()"><B>isLenient()</B></A> -
554 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
555 <DD>Returns true if this writer has relaxed syntax rules.
556 <DT><A HREF="./com/google/gson/JsonPrimitive.html#isNumber()"><B>isNumber()</B></A> -
557 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
558 <DD>Check whether this primitive contains a Number.
559 <DT><A HREF="./com/google/gson/JsonPrimitive.html#isString()"><B>isString()</B></A> -
560 Method in class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
561 <DD>Check whether this primitive contains a String value.
562 <DT><A HREF="./com/google/gson/JsonArray.html#iterator()"><B>iterator()</B></A> -
563 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
564 <DD>Returns an iterator to navigate the elemetns of the array.
565 </DL>
566 <HR>
567 <A NAME="_J_"><!-- --></A><H2>
568 <B>J</B></H2>
569 <DL>
570 <DT><A HREF="./com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>JsonAdapter</B></A> - Annotation Type in <A HREF="./com/google/gson/annotations/package-summary.html">com.google.gson.annotations</A><DD>An annotation that indicates the Gson <A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson"><CODE>TypeAdapter</CODE></A> to use with a class
571 or field.<DT><A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson"><B>JsonArray</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A class representing an array type in Json.<DT><A HREF="./com/google/gson/JsonArray.html#JsonArray()"><B>JsonArray()</B></A> -
572 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
573 <DD>Creates an empty JsonArray.
574 <DT><A HREF="./com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>JsonDeserializationContext</B></A> - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Context for deserialization that is passed to a custom deserializer during invocation of its
575 <A HREF="./com/google/gson/JsonDeserializer.html#deserialize(com.google.gson.JsonElement, java.lang.reflect.Type, com.google.gson.JsonDeserializationContext)"><CODE>JsonDeserializer.deserialize(JsonElement, Type, JsonDeserializationContext)</CODE></A>
576 method.<DT><A HREF="./com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>JsonDeserializer</B></A>&lt;<A HREF="./com/google/gson/JsonDeserializer.html" title="type parameter in JsonDeserializer">T</A>&gt; - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Interface representing a custom deserializer for Json.<DT><A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><B>JsonElement</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A class representing an element of Json.<DT><A HREF="./com/google/gson/JsonElement.html#JsonElement()"><B>JsonElement()</B></A> -
577 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
578 <DD>&nbsp;
579 <DT><A HREF="./com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>JsonIOException</B></A> - Exception in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>This exception is raised when Gson was unable to read an input stream
580 or write to one.<DT><A HREF="./com/google/gson/JsonIOException.html#JsonIOException(java.lang.String)"><B>JsonIOException(String)</B></A> -
581 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>
582 <DD>&nbsp;
583 <DT><A HREF="./com/google/gson/JsonIOException.html#JsonIOException(java.lang.String, java.lang.Throwable)"><B>JsonIOException(String, Throwable)</B></A> -
584 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>
585 <DD>&nbsp;
586 <DT><A HREF="./com/google/gson/JsonIOException.html#JsonIOException(java.lang.Throwable)"><B>JsonIOException(Throwable)</B></A> -
587 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonIOException.html" title="class in com.google.gson">JsonIOException</A>
588 <DD>Creates exception with the specified cause.
589 <DT><A HREF="./com/google/gson/JsonNull.html" title="class in com.google.gson"><B>JsonNull</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A class representing a Json <code>null</code> value.<DT><A HREF="./com/google/gson/JsonNull.html#JsonNull()"><B>JsonNull()</B></A> -
590 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonNull.html" title="class in com.google.gson">JsonNull</A>
591 <DD><B>Deprecated.</B>&nbsp;
592 <DT><A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson"><B>JsonObject</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A class representing an object type in Json.<DT><A HREF="./com/google/gson/JsonObject.html#JsonObject()"><B>JsonObject()</B></A> -
593 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
594 <DD>&nbsp;
595 <DT><A HREF="./com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>JsonParseException</B></A> - Exception in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>This exception is raised if there is a serious issue that occurs during parsing of a Json
596 string.<DT><A HREF="./com/google/gson/JsonParseException.html#JsonParseException(java.lang.String)"><B>JsonParseException(String)</B></A> -
597 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A>
598 <DD>Creates exception with the specified message.
599 <DT><A HREF="./com/google/gson/JsonParseException.html#JsonParseException(java.lang.String, java.lang.Throwable)"><B>JsonParseException(String, Throwable)</B></A> -
600 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A>
601 <DD>Creates exception with the specified message and cause.
602 <DT><A HREF="./com/google/gson/JsonParseException.html#JsonParseException(java.lang.Throwable)"><B>JsonParseException(Throwable)</B></A> -
603 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A>
604 <DD>Creates exception with the specified cause.
605 <DT><A HREF="./com/google/gson/JsonParser.html" title="class in com.google.gson"><B>JsonParser</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A parser to parse Json into a parse tree of <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s<DT><A HREF="./com/google/gson/JsonParser.html#JsonParser()"><B>JsonParser()</B></A> -
606 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonParser.html" title="class in com.google.gson">JsonParser</A>
607 <DD>&nbsp;
608 <DT><A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>JsonPrimitive</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A class representing a Json primitive value.<DT><A HREF="./com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.Boolean)"><B>JsonPrimitive(Boolean)</B></A> -
609 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
610 <DD>Create a primitive containing a boolean value.
611 <DT><A HREF="./com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.Number)"><B>JsonPrimitive(Number)</B></A> -
612 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
613 <DD>Create a primitive containing a <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Number.html?is-external=true" title="class or interface in java.lang"><CODE>Number</CODE></A>.
614 <DT><A HREF="./com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.String)"><B>JsonPrimitive(String)</B></A> -
615 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
616 <DD>Create a primitive containing a String value.
617 <DT><A HREF="./com/google/gson/JsonPrimitive.html#JsonPrimitive(java.lang.Character)"><B>JsonPrimitive(Character)</B></A> -
618 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonPrimitive.html" title="class in com.google.gson">JsonPrimitive</A>
619 <DD>Create a primitive containing a character.
620 <DT><A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><B>JsonReader</B></A> - Class in <A HREF="./com/google/gson/stream/package-summary.html">com.google.gson.stream</A><DD>Reads a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
621 encoded value as a stream of tokens.<DT><A HREF="./com/google/gson/stream/JsonReader.html#JsonReader(java.io.Reader)"><B>JsonReader(Reader)</B></A> -
622 Constructor for class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
623 <DD>Creates a new instance that reads a JSON-encoded stream from <code>in</code>.
624 <DT><A HREF="./com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>JsonSerializationContext</B></A> - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Context for serialization that is passed to a custom serializer during invocation of its
625 <A HREF="./com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><CODE>JsonSerializer.serialize(Object, Type, JsonSerializationContext)</CODE></A> method.<DT><A HREF="./com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>JsonSerializer</B></A>&lt;<A HREF="./com/google/gson/JsonSerializer.html" title="type parameter in JsonSerializer">T</A>&gt; - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Interface representing a custom serializer for Json.<DT><A HREF="./com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>JsonStreamParser</B></A> - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>A streaming parser that allows reading of multiple <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s from the specified reader
626 asynchronously.<DT><A HREF="./com/google/gson/JsonStreamParser.html#JsonStreamParser(java.lang.String)"><B>JsonStreamParser(String)</B></A> -
627 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A>
628 <DD>&nbsp;
629 <DT><A HREF="./com/google/gson/JsonStreamParser.html#JsonStreamParser(java.io.Reader)"><B>JsonStreamParser(Reader)</B></A> -
630 Constructor for class com.google.gson.<A HREF="./com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A>
631 <DD>&nbsp;
632 <DT><A HREF="./com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>JsonSyntaxException</B></A> - Exception in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>This exception is raised when Gson attempts to read (or write) a malformed
633 JSON element.<DT><A HREF="./com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.String)"><B>JsonSyntaxException(String)</B></A> -
634 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A>
635 <DD>&nbsp;
636 <DT><A HREF="./com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.String, java.lang.Throwable)"><B>JsonSyntaxException(String, Throwable)</B></A> -
637 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A>
638 <DD>&nbsp;
639 <DT><A HREF="./com/google/gson/JsonSyntaxException.html#JsonSyntaxException(java.lang.Throwable)"><B>JsonSyntaxException(Throwable)</B></A> -
640 Constructor for exception com.google.gson.<A HREF="./com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">JsonSyntaxException</A>
641 <DD>Creates exception with the specified cause.
642 <DT><A HREF="./com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>JsonToken</B></A> - Enum in <A HREF="./com/google/gson/stream/package-summary.html">com.google.gson.stream</A><DD>A structure, name or value type in a JSON-encoded string.<DT><A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>JsonWriter</B></A> - Class in <A HREF="./com/google/gson/stream/package-summary.html">com.google.gson.stream</A><DD>Writes a JSON (<a href="http://www.ietf.org/rfc/rfc4627.txt">RFC 4627</a>)
643 encoded value to a stream, one token at a time.<DT><A HREF="./com/google/gson/stream/JsonWriter.html#JsonWriter(java.io.Writer)"><B>JsonWriter(Writer)</B></A> -
644 Constructor for class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
645 <DD>Creates a new instance that writes a JSON-encoded stream to <code>out</code>.
646 </DL>
647 <HR>
648 <A NAME="_L_"><!-- --></A><H2>
649 <B>L</B></H2>
650 <DL>
651 <DT><A HREF="./com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>LongSerializationPolicy</B></A> - Enum in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Defines the expected format for a <code>long</code> or <code>Long</code> type when its serialized.</DL>
652 <HR>
653 <A NAME="_M_"><!-- --></A><H2>
654 <B>M</B></H2>
655 <DL>
656 <DT><A HREF="./com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><B>MalformedJsonException</B></A> - Exception in <A HREF="./com/google/gson/stream/package-summary.html">com.google.gson.stream</A><DD>Thrown when a reader encounters malformed JSON.<DT><A HREF="./com/google/gson/stream/MalformedJsonException.html#MalformedJsonException(java.lang.String)"><B>MalformedJsonException(String)</B></A> -
657 Constructor for exception com.google.gson.stream.<A HREF="./com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream">MalformedJsonException</A>
658 <DD>&nbsp;
659 <DT><A HREF="./com/google/gson/stream/MalformedJsonException.html#MalformedJsonException(java.lang.String, java.lang.Throwable)"><B>MalformedJsonException(String, Throwable)</B></A> -
660 Constructor for exception com.google.gson.stream.<A HREF="./com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream">MalformedJsonException</A>
661 <DD>&nbsp;
662 <DT><A HREF="./com/google/gson/stream/MalformedJsonException.html#MalformedJsonException(java.lang.Throwable)"><B>MalformedJsonException(Throwable)</B></A> -
663 Constructor for exception com.google.gson.stream.<A HREF="./com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream">MalformedJsonException</A>
664 <DD>&nbsp;
665 </DL>
666 <HR>
667 <A NAME="_N_"><!-- --></A><H2>
668 <B>N</B></H2>
669 <DL>
670 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#name(java.lang.String)"><B>name(String)</B></A> -
671 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
672 <DD>Encodes the property name.
673 <DT><A HREF="./com/google/gson/JsonStreamParser.html#next()"><B>next()</B></A> -
674 Method in class com.google.gson.<A HREF="./com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A>
675 <DD>Returns the next available <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A> on the reader.
676 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextBoolean()"><B>nextBoolean()</B></A> -
677 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
678 <DD>Returns the <A HREF="./com/google/gson/stream/JsonToken.html#BOOLEAN"><CODE>boolean</CODE></A> value of the next token,
679 consuming it.
680 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextDouble()"><B>nextDouble()</B></A> -
681 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
682 <DD>Returns the <A HREF="./com/google/gson/stream/JsonToken.html#NUMBER"><CODE>double</CODE></A> value of the next token,
683 consuming it.
684 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextInt()"><B>nextInt()</B></A> -
685 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
686 <DD>Returns the <A HREF="./com/google/gson/stream/JsonToken.html#NUMBER"><CODE>int</CODE></A> value of the next token,
687 consuming it.
688 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextLong()"><B>nextLong()</B></A> -
689 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
690 <DD>Returns the <A HREF="./com/google/gson/stream/JsonToken.html#NUMBER"><CODE>long</CODE></A> value of the next token,
691 consuming it.
692 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextName()"><B>nextName()</B></A> -
693 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
694 <DD>Returns the next token, a <A HREF="./com/google/gson/stream/JsonToken.html#NAME"><CODE>property name</CODE></A>, and
695 consumes it.
696 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextNull()"><B>nextNull()</B></A> -
697 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
698 <DD>Consumes the next token from the JSON stream and asserts that it is a
699 literal null.
700 <DT><A HREF="./com/google/gson/stream/JsonReader.html#nextString()"><B>nextString()</B></A> -
701 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
702 <DD>Returns the <A HREF="./com/google/gson/stream/JsonToken.html#STRING"><CODE>string</CODE></A> value of the next token,
703 consuming it.
704 <DT><A HREF="./com/google/gson/TypeAdapter.html#nullSafe()"><B>nullSafe()</B></A> -
705 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
706 <DD>This wrapper method is used to make a type adapter null tolerant.
707 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#nullValue()"><B>nullValue()</B></A> -
708 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
709 <DD>Encodes <code>null</code>.
710 </DL>
711 <HR>
712 <A NAME="_P_"><!-- --></A><H2>
713 <B>P</B></H2>
714 <DL>
715 <DT><A HREF="./com/google/gson/JsonParser.html#parse(java.lang.String)"><B>parse(String)</B></A> -
716 Method in class com.google.gson.<A HREF="./com/google/gson/JsonParser.html" title="class in com.google.gson">JsonParser</A>
717 <DD>Parses the specified JSON string into a parse tree
718 <DT><A HREF="./com/google/gson/JsonParser.html#parse(java.io.Reader)"><B>parse(Reader)</B></A> -
719 Method in class com.google.gson.<A HREF="./com/google/gson/JsonParser.html" title="class in com.google.gson">JsonParser</A>
720 <DD>Parses the specified JSON string into a parse tree
721 <DT><A HREF="./com/google/gson/JsonParser.html#parse(com.google.gson.stream.JsonReader)"><B>parse(JsonReader)</B></A> -
722 Method in class com.google.gson.<A HREF="./com/google/gson/JsonParser.html" title="class in com.google.gson">JsonParser</A>
723 <DD>Returns the next value from the JSON stream as a parse tree.
724 <DT><A HREF="./com/google/gson/stream/JsonReader.html#peek()"><B>peek()</B></A> -
725 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
726 <DD>Returns the type of the next token without consuming it.
727 </DL>
728 <HR>
729 <A NAME="_R_"><!-- --></A><H2>
730 <B>R</B></H2>
731 <DL>
732 <DT><A HREF="./com/google/gson/TypeAdapter.html#read(com.google.gson.stream.JsonReader)"><B>read(JsonReader)</B></A> -
733 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
734 <DD>Reads one JSON value (an array, object, string, number, boolean or null)
735 and converts it to a Java object.
736 <DT><A HREF="./com/google/gson/GsonBuilder.html#registerTypeAdapter(java.lang.reflect.Type, java.lang.Object)"><B>registerTypeAdapter(Type, Object)</B></A> -
737 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
738 <DD>Configures Gson for custom serialization or deserialization.
739 <DT><A HREF="./com/google/gson/GsonBuilder.html#registerTypeAdapterFactory(com.google.gson.TypeAdapterFactory)"><B>registerTypeAdapterFactory(TypeAdapterFactory)</B></A> -
740 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
741 <DD>Register a factory for type adapters.
742 <DT><A HREF="./com/google/gson/GsonBuilder.html#registerTypeHierarchyAdapter(java.lang.Class, java.lang.Object)"><B>registerTypeHierarchyAdapter(Class&lt;?&gt;, Object)</B></A> -
743 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
744 <DD>Configures Gson for custom serialization or deserialization for an inheritance type hierarchy.
745 <DT><A HREF="./com/google/gson/JsonArray.html#remove(com.google.gson.JsonElement)"><B>remove(JsonElement)</B></A> -
746 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
747 <DD>Removes the first occurrence of the specified element from this array, if it is present.
748 <DT><A HREF="./com/google/gson/JsonArray.html#remove(int)"><B>remove(int)</B></A> -
749 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
750 <DD>Removes the element at the specified position in this array.
751 <DT><A HREF="./com/google/gson/JsonObject.html#remove(java.lang.String)"><B>remove(String)</B></A> -
752 Method in class com.google.gson.<A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson">JsonObject</A>
753 <DD>Removes the <code>property</code> from this <A HREF="./com/google/gson/JsonObject.html" title="class in com.google.gson"><CODE>JsonObject</CODE></A>.
754 <DT><A HREF="./com/google/gson/JsonStreamParser.html#remove()"><B>remove()</B></A> -
755 Method in class com.google.gson.<A HREF="./com/google/gson/JsonStreamParser.html" title="class in com.google.gson">JsonStreamParser</A>
756 <DD>This optional <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util"><CODE>Iterator</CODE></A> method is not relevant for stream parsing and hence is not
757 implemented.
758 </DL>
759 <HR>
760 <A NAME="_S_"><!-- --></A><H2>
761 <B>S</B></H2>
762 <DL>
763 <DT><A HREF="./com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object)"><B>serialize(Object)</B></A> -
764 Method in interface com.google.gson.<A HREF="./com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A>
765 <DD>Invokes default serialization on the specified object.
766 <DT><A HREF="./com/google/gson/JsonSerializationContext.html#serialize(java.lang.Object, java.lang.reflect.Type)"><B>serialize(Object, Type)</B></A> -
767 Method in interface com.google.gson.<A HREF="./com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson">JsonSerializationContext</A>
768 <DD>Invokes default serialization on the specified object passing the specific type information.
769 <DT><A HREF="./com/google/gson/JsonSerializer.html#serialize(T, java.lang.reflect.Type, com.google.gson.JsonSerializationContext)"><B>serialize(T, Type, JsonSerializationContext)</B></A> -
770 Method in interface com.google.gson.<A HREF="./com/google/gson/JsonSerializer.html" title="interface in com.google.gson">JsonSerializer</A>
771 <DD>Gson invokes this call-back method during serialization when it encounters a field of the
772 specified type.
773 <DT><A HREF="./com/google/gson/LongSerializationPolicy.html#serialize(java.lang.Long)"><B>serialize(Long)</B></A> -
774 Method in enum com.google.gson.<A HREF="./com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>
775 <DD>Serialize this <code>value</code> using this serialization policy.
776 <DT><A HREF="./com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>SerializedName</B></A> - Annotation Type in <A HREF="./com/google/gson/annotations/package-summary.html">com.google.gson.annotations</A><DD>An annotation that indicates this member should be serialized to JSON with
777 the provided name value as its field name.<DT><A HREF="./com/google/gson/GsonBuilder.html#serializeNulls()"><B>serializeNulls()</B></A> -
778 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
779 <DD>Configure Gson to serialize null fields.
780 <DT><A HREF="./com/google/gson/GsonBuilder.html#serializeSpecialFloatingPointValues()"><B>serializeSpecialFloatingPointValues()</B></A> -
781 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
782 <DD>Section 2.4 of <a href="http://www.ietf.org/rfc/rfc4627.txt">JSON specification</a> disallows
783 special double values (NaN, Infinity, -Infinity).
784 <DT><A HREF="./com/google/gson/JsonArray.html#set(int, com.google.gson.JsonElement)"><B>set(int, JsonElement)</B></A> -
785 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
786 <DD>Replaces the element at the specified position in this array with the specified element.
787 <DT><A HREF="./com/google/gson/GsonBuilder.html#setDateFormat(java.lang.String)"><B>setDateFormat(String)</B></A> -
788 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
789 <DD>Configures Gson to serialize <code>Date</code> objects according to the pattern provided.
790 <DT><A HREF="./com/google/gson/GsonBuilder.html#setDateFormat(int)"><B>setDateFormat(int)</B></A> -
791 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
792 <DD>Configures Gson to to serialize <code>Date</code> objects according to the style value provided.
793 <DT><A HREF="./com/google/gson/GsonBuilder.html#setDateFormat(int, int)"><B>setDateFormat(int, int)</B></A> -
794 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
795 <DD>Configures Gson to to serialize <code>Date</code> objects according to the style value provided.
796 <DT><A HREF="./com/google/gson/GsonBuilder.html#setExclusionStrategies(com.google.gson.ExclusionStrategy...)"><B>setExclusionStrategies(ExclusionStrategy...)</B></A> -
797 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
798 <DD>Configures Gson to apply a set of exclusion strategies during both serialization and
799 deserialization.
800 <DT><A HREF="./com/google/gson/GsonBuilder.html#setFieldNamingPolicy(com.google.gson.FieldNamingPolicy)"><B>setFieldNamingPolicy(FieldNamingPolicy)</B></A> -
801 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
802 <DD>Configures Gson to apply a specific naming policy to an object's field during serialization
803 and deserialization.
804 <DT><A HREF="./com/google/gson/GsonBuilder.html#setFieldNamingStrategy(com.google.gson.FieldNamingStrategy)"><B>setFieldNamingStrategy(FieldNamingStrategy)</B></A> -
805 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
806 <DD>Configures Gson to apply a specific naming policy strategy to an object's field during
807 serialization and deserialization.
808 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#setHtmlSafe(boolean)"><B>setHtmlSafe(boolean)</B></A> -
809 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
810 <DD>Configure this writer to emit JSON that's safe for direct inclusion in HTML
811 and XML documents.
812 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#setIndent(java.lang.String)"><B>setIndent(String)</B></A> -
813 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
814 <DD>Sets the indentation string to be repeated for each level of indentation
815 in the encoded document.
816 <DT><A HREF="./com/google/gson/stream/JsonReader.html#setLenient(boolean)"><B>setLenient(boolean)</B></A> -
817 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
818 <DD>Configure this parser to be be liberal in what it accepts.
819 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#setLenient(boolean)"><B>setLenient(boolean)</B></A> -
820 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
821 <DD>Configure this writer to relax its syntax rules.
822 <DT><A HREF="./com/google/gson/GsonBuilder.html#setLongSerializationPolicy(com.google.gson.LongSerializationPolicy)"><B>setLongSerializationPolicy(LongSerializationPolicy)</B></A> -
823 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
824 <DD>Configures Gson to apply a specific serialization policy for <code>Long</code> and <code>long</code>
825 objects.
826 <DT><A HREF="./com/google/gson/GsonBuilder.html#setPrettyPrinting()"><B>setPrettyPrinting()</B></A> -
827 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
828 <DD>Configures Gson to output Json that fits in a page for pretty printing.
829 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#setSerializeNulls(boolean)"><B>setSerializeNulls(boolean)</B></A> -
830 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
831 <DD>Sets whether object members are serialized when their value is null.
832 <DT><A HREF="./com/google/gson/GsonBuilder.html#setVersion(double)"><B>setVersion(double)</B></A> -
833 Method in class com.google.gson.<A HREF="./com/google/gson/GsonBuilder.html" title="class in com.google.gson">GsonBuilder</A>
834 <DD>Configures Gson to enable versioning support.
835 <DT><A HREF="./com/google/gson/ExclusionStrategy.html#shouldSkipClass(java.lang.Class)"><B>shouldSkipClass(Class&lt;?&gt;)</B></A> -
836 Method in interface com.google.gson.<A HREF="./com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>
837 <DD>&nbsp;
838 <DT><A HREF="./com/google/gson/ExclusionStrategy.html#shouldSkipField(com.google.gson.FieldAttributes)"><B>shouldSkipField(FieldAttributes)</B></A> -
839 Method in interface com.google.gson.<A HREF="./com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson">ExclusionStrategy</A>
840 <DD>&nbsp;
841 <DT><A HREF="./com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>Since</B></A> - Annotation Type in <A HREF="./com/google/gson/annotations/package-summary.html">com.google.gson.annotations</A><DD>An annotation that indicates the version number since a member or a type has been present.<DT><A HREF="./com/google/gson/JsonArray.html#size()"><B>size()</B></A> -
842 Method in class com.google.gson.<A HREF="./com/google/gson/JsonArray.html" title="class in com.google.gson">JsonArray</A>
843 <DD>Returns the number of elements in the array.
844 <DT><A HREF="./com/google/gson/stream/JsonReader.html#skipValue()"><B>skipValue()</B></A> -
845 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
846 <DD>Skips the next value recursively.
847 </DL>
848 <HR>
849 <A NAME="_T_"><!-- --></A><H2>
850 <B>T</B></H2>
851 <DL>
852 <DT><A HREF="./com/google/gson/Gson.html#toJson(java.lang.Object)"><B>toJson(Object)</B></A> -
853 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
854 <DD>This method serializes the specified object into its equivalent Json representation.
855 <DT><A HREF="./com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type)"><B>toJson(Object, Type)</B></A> -
856 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
857 <DD>This method serializes the specified object, including those of generic types, into its
858 equivalent Json representation.
859 <DT><A HREF="./com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.Appendable)"><B>toJson(Object, Appendable)</B></A> -
860 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
861 <DD>This method serializes the specified object into its equivalent Json representation.
862 <DT><A HREF="./com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, java.lang.Appendable)"><B>toJson(Object, Type, Appendable)</B></A> -
863 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
864 <DD>This method serializes the specified object, including those of generic types, into its
865 equivalent Json representation.
866 <DT><A HREF="./com/google/gson/Gson.html#toJson(java.lang.Object, java.lang.reflect.Type, com.google.gson.stream.JsonWriter)"><B>toJson(Object, Type, JsonWriter)</B></A> -
867 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
868 <DD>Writes the JSON representation of <code>src</code> of type <code>typeOfSrc</code> to
869 <code>writer</code>.
870 <DT><A HREF="./com/google/gson/Gson.html#toJson(com.google.gson.JsonElement)"><B>toJson(JsonElement)</B></A> -
871 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
872 <DD>Converts a tree of <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s into its equivalent JSON representation.
873 <DT><A HREF="./com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, java.lang.Appendable)"><B>toJson(JsonElement, Appendable)</B></A> -
874 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
875 <DD>Writes out the equivalent JSON for a tree of <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.
876 <DT><A HREF="./com/google/gson/Gson.html#toJson(com.google.gson.JsonElement, com.google.gson.stream.JsonWriter)"><B>toJson(JsonElement, JsonWriter)</B></A> -
877 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
878 <DD>Writes the JSON for <code>jsonElement</code> to <code>writer</code>.
879 <DT><A HREF="./com/google/gson/TypeAdapter.html#toJson(java.io.Writer, T)"><B>toJson(Writer, T)</B></A> -
880 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
881 <DD>Converts <code>value</code> to a JSON document and writes it to <code>out</code>.
882 <DT><A HREF="./com/google/gson/TypeAdapter.html#toJson(T)"><B>toJson(T)</B></A> -
883 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
884 <DD>Converts <code>value</code> to a JSON document.
885 <DT><A HREF="./com/google/gson/Gson.html#toJsonTree(java.lang.Object)"><B>toJsonTree(Object)</B></A> -
886 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
887 <DD>This method serializes the specified object into its equivalent representation as a tree of
888 <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.
889 <DT><A HREF="./com/google/gson/Gson.html#toJsonTree(java.lang.Object, java.lang.reflect.Type)"><B>toJsonTree(Object, Type)</B></A> -
890 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
891 <DD>This method serializes the specified object, including those of generic types, into its
892 equivalent representation as a tree of <A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson"><CODE>JsonElement</CODE></A>s.
893 <DT><A HREF="./com/google/gson/TypeAdapter.html#toJsonTree(T)"><B>toJsonTree(T)</B></A> -
894 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
895 <DD>Converts <code>value</code> to a JSON tree.
896 <DT><A HREF="./com/google/gson/Gson.html#toString()"><B>toString()</B></A> -
897 Method in class com.google.gson.<A HREF="./com/google/gson/Gson.html" title="class in com.google.gson">Gson</A>
898 <DD>&nbsp;
899 <DT><A HREF="./com/google/gson/JsonElement.html#toString()"><B>toString()</B></A> -
900 Method in class com.google.gson.<A HREF="./com/google/gson/JsonElement.html" title="class in com.google.gson">JsonElement</A>
901 <DD>Returns a String representation of this element.
902 <DT><A HREF="./com/google/gson/reflect/TypeToken.html#toString()"><B>toString()</B></A> -
903 Method in class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
904 <DD>&nbsp;
905 <DT><A HREF="./com/google/gson/stream/JsonReader.html#toString()"><B>toString()</B></A> -
906 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream">JsonReader</A>
907 <DD>&nbsp;
908 <DT><A HREF="./com/google/gson/FieldNamingStrategy.html#translateName(java.lang.reflect.Field)"><B>translateName(Field)</B></A> -
909 Method in interface com.google.gson.<A HREF="./com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>
910 <DD>Translates the field name into its JSON field name representation.
911 <DT><A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>TypeAdapter</B></A>&lt;<A HREF="./com/google/gson/TypeAdapter.html" title="type parameter in TypeAdapter">T</A>&gt; - Class in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Converts Java objects to and from JSON.<DT><A HREF="./com/google/gson/TypeAdapter.html#TypeAdapter()"><B>TypeAdapter()</B></A> -
912 Constructor for class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
913 <DD>&nbsp;
914 <DT><A HREF="./com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><B>TypeAdapterFactory</B></A> - Interface in <A HREF="./com/google/gson/package-summary.html">com.google.gson</A><DD>Creates type adapters for set of related types.<DT><A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><B>TypeToken</B></A>&lt;<A HREF="./com/google/gson/reflect/TypeToken.html" title="type parameter in TypeToken">T</A>&gt; - Class in <A HREF="./com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A><DD>Represents a generic type <code>T</code>.<DT><A HREF="./com/google/gson/reflect/TypeToken.html#TypeToken()"><B>TypeToken()</B></A> -
915 Constructor for class com.google.gson.reflect.<A HREF="./com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect">TypeToken</A>
916 <DD>Constructs a new type literal.
917 </DL>
918 <HR>
919 <A NAME="_U_"><!-- --></A><H2>
920 <B>U</B></H2>
921 <DL>
922 <DT><A HREF="./com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><B>Until</B></A> - Annotation Type in <A HREF="./com/google/gson/annotations/package-summary.html">com.google.gson.annotations</A><DD>An annotation that indicates the version number until a member or a type should be present.</DL>
923 <HR>
924 <A NAME="_V_"><!-- --></A><H2>
925 <B>V</B></H2>
926 <DL>
927 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#value(java.lang.String)"><B>value(String)</B></A> -
928 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
929 <DD>Encodes <code>value</code>.
930 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#value(boolean)"><B>value(boolean)</B></A> -
931 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
932 <DD>Encodes <code>value</code>.
933 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#value(double)"><B>value(double)</B></A> -
934 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
935 <DD>Encodes <code>value</code>.
936 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#value(long)"><B>value(long)</B></A> -
937 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
938 <DD>Encodes <code>value</code>.
939 <DT><A HREF="./com/google/gson/stream/JsonWriter.html#value(java.lang.Number)"><B>value(Number)</B></A> -
940 Method in class com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream">JsonWriter</A>
941 <DD>Encodes <code>value</code>.
942 <DT><A HREF="./com/google/gson/FieldNamingPolicy.html#valueOf(java.lang.String)"><B>valueOf(String)</B></A> -
943 Static method in enum com.google.gson.<A HREF="./com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>
944 <DD>Returns the enum constant of this type with the specified name.
945 <DT><A HREF="./com/google/gson/LongSerializationPolicy.html#valueOf(java.lang.String)"><B>valueOf(String)</B></A> -
946 Static method in enum com.google.gson.<A HREF="./com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>
947 <DD>Returns the enum constant of this type with the specified name.
948 <DT><A HREF="./com/google/gson/stream/JsonToken.html#valueOf(java.lang.String)"><B>valueOf(String)</B></A> -
949 Static method in enum com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>
950 <DD>Returns the enum constant of this type with the specified name.
951 <DT><A HREF="./com/google/gson/FieldNamingPolicy.html#values()"><B>values()</B></A> -
952 Static method in enum com.google.gson.<A HREF="./com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson">FieldNamingPolicy</A>
953 <DD>Returns an array containing the constants of this enum type, in
954 the order they are declared.
955 <DT><A HREF="./com/google/gson/LongSerializationPolicy.html#values()"><B>values()</B></A> -
956 Static method in enum com.google.gson.<A HREF="./com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson">LongSerializationPolicy</A>
957 <DD>Returns an array containing the constants of this enum type, in
958 the order they are declared.
959 <DT><A HREF="./com/google/gson/stream/JsonToken.html#values()"><B>values()</B></A> -
960 Static method in enum com.google.gson.stream.<A HREF="./com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream">JsonToken</A>
961 <DD>Returns an array containing the constants of this enum type, in
962 the order they are declared.
963 </DL>
964 <HR>
965 <A NAME="_W_"><!-- --></A><H2>
966 <B>W</B></H2>
967 <DL>
968 <DT><A HREF="./com/google/gson/TypeAdapter.html#write(com.google.gson.stream.JsonWriter, T)"><B>write(JsonWriter, T)</B></A> -
969 Method in class com.google.gson.<A HREF="./com/google/gson/TypeAdapter.html" title="class in com.google.gson">TypeAdapter</A>
970 <DD>Writes one JSON value (an array, object, string, number, boolean or null)
971 for <code>value</code>.
972 </DL>
973 <HR>
974 <A HREF="#_A_">A</A> <A HREF="#_B_">B</A> <A HREF="#_C_">C</A> <A HREF="#_D_">D</A> <A HREF="#_E_">E</A> <A HREF="#_F_">F</A> <A HREF="#_G_">G</A> <A HREF="#_H_">H</A> <A HREF="#_I_">I</A> <A HREF="#_J_">J</A> <A HREF="#_L_">L</A> <A HREF="#_M_">M</A> <A HREF="#_N_">N</A> <A HREF="#_P_">P</A> <A HREF="#_R_">R</A> <A HREF="#_S_">S</A> <A HREF="#_T_">T</A> <A HREF="#_U_">U</A> <A HREF="#_V_">V</A> <A HREF="#_W_">W</A>
975
976 <!-- ======= START OF BOTTOM NAVBAR ====== -->
977 <A NAME="navbar_bottom"><!-- --></A>
978 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
979 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
980 <TR>
981 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
982 <A NAME="navbar_bottom_firstrow"><!-- --></A>
983 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
984 <TR ALIGN="center" VALIGN="top">
985 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
986 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
987 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
988 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
989 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
990 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
991 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Index</B></FONT>&nbsp;</TD>
992 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="./help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
993 </TR>
994 </TABLE>
995 </TD>
996 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
997 </EM>
998 </TD>
999 </TR>
1000
1001 <TR>
1002 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
1003 &nbsp;PREV&nbsp;
1004 &nbsp;NEXT</FONT></TD>
1005 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
1006 <A HREF="./index.html?index-all.html" target="_top"><B>FRAMES</B></A> &nbsp;
1007 &nbsp;<A HREF="index-all.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
1008 &nbsp;<SCRIPT type="text/javascript">
1009 <!--
1010 if(window==top) {
1011 document.writeln('<A HREF="./allclasses-noframe.html"><B>All Classes</B></A>');
1012 }
1013 //-->
1014 </SCRIPT>
1015 <NOSCRIPT>
1016 <A HREF="./allclasses-noframe.html"><B>All Classes</B></A>
1017 </NOSCRIPT>
1018
1019
1020 </FONT></TD>
1021 </TR>
1022 </TABLE>
1023 <A NAME="skip-navbar_bottom"></A>
1024 <!-- ======== END OF BOTTOM NAVBAR ======= -->
1025
1026 <HR>
1027 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
1028 </BODY>
1029 </HTML>
+0
-74
gson/docs/javadocs/index.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc on Thu Nov 20 01:11:55 PST 2014-->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Gson 2.3.1 API
8 </TITLE>
9 <SCRIPT type="text/javascript">
10 targetPage = "" + window.location.search;
11 if (targetPage != "" && targetPage != "undefined")
12 targetPage = targetPage.substring(1);
13 if (targetPage.indexOf(":") != -1 || (targetPage != "" && !validURL(targetPage)))
14 targetPage = "undefined";
15 function validURL(url) {
16 var pos = url.indexOf(".html");
17 if (pos == -1 || pos != url.length - 5)
18 return false;
19 var allowNumber = false;
20 var allowSep = false;
21 var seenDot = false;
22 for (var i = 0; i < url.length - 5; i++) {
23 var ch = url.charAt(i);
24 if ('a' <= ch && ch <= 'z' ||
25 'A' <= ch && ch <= 'Z' ||
26 ch == '$' ||
27 ch == '_') {
28 allowNumber = true;
29 allowSep = true;
30 } else if ('0' <= ch && ch <= '9'
31 || ch == '-') {
32 if (!allowNumber)
33 return false;
34 } else if (ch == '/' || ch == '.') {
35 if (!allowSep)
36 return false;
37 allowNumber = false;
38 allowSep = false;
39 if (ch == '.')
40 seenDot = true;
41 if (ch == '/' && seenDot)
42 return false;
43 } else {
44 return false;
45 }
46 }
47 return true;
48 }
49 function loadFrames() {
50 if (targetPage != "" && targetPage != "undefined")
51 top.classFrame.location = top.targetPage;
52 }
53 </SCRIPT>
54 <NOSCRIPT>
55 </NOSCRIPT>
56 </HEAD>
57 <FRAMESET cols="20%,80%" title="" onLoad="top.loadFrames()">
58 <FRAMESET rows="30%,70%" title="" onLoad="top.loadFrames()">
59 <FRAME src="overview-frame.html" name="packageListFrame" title="All Packages">
60 <FRAME src="allclasses-frame.html" name="packageFrame" title="All classes and interfaces (except non-static nested types)">
61 </FRAMESET>
62 <FRAME src="overview-summary.html" name="classFrame" title="Package, class and interface descriptions" scrolling="yes">
63 <NOFRAMES>
64 <H2>
65 Frame Alert</H2>
66
67 <P>
68 This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client.
69 <BR>
70 Link to<A HREF="overview-summary.html">Non-frame version.</A>
71 </NOFRAMES>
72 </FRAMESET>
73 </HTML>
+0
-49
gson/docs/javadocs/overview-frame.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Overview List (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14
15 </HEAD>
16
17 <BODY BGCOLOR="white">
18
19 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
20 <TR>
21 <TH ALIGN="left" NOWRAP><FONT size="+1" CLASS="FrameTitleFont">
22 <B></B></FONT></TH>
23 </TR>
24 </TABLE>
25
26 <TABLE BORDER="0" WIDTH="100%" SUMMARY="">
27 <TR>
28 <TD NOWRAP><FONT CLASS="FrameItemFont"><A HREF="allclasses-frame.html" target="packageFrame">All Classes</A></FONT>
29 <P>
30 <FONT size="+1" CLASS="FrameHeadingFont">
31 Packages</FONT>
32 <BR>
33 <FONT CLASS="FrameItemFont"><A HREF="com/google/gson/package-frame.html" target="packageFrame">com.google.gson</A></FONT>
34 <BR>
35 <FONT CLASS="FrameItemFont"><A HREF="com/google/gson/annotations/package-frame.html" target="packageFrame">com.google.gson.annotations</A></FONT>
36 <BR>
37 <FONT CLASS="FrameItemFont"><A HREF="com/google/gson/reflect/package-frame.html" target="packageFrame">com.google.gson.reflect</A></FONT>
38 <BR>
39 <FONT CLASS="FrameItemFont"><A HREF="com/google/gson/stream/package-frame.html" target="packageFrame">com.google.gson.stream</A></FONT>
40 <BR>
41 </TD>
42 </TR>
43 </TABLE>
44
45 <P>
46 &nbsp;
47 </BODY>
48 </HTML>
+0
-170
gson/docs/javadocs/overview-summary.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Overview (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Overview (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Overview</B></FONT>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="index.html?overview-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="overview-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H1>
84 Gson 2.3.1 API
85 </H1>
86 </CENTER>
87
88 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
89 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
90 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
91 <B>Packages</B></FONT></TH>
92 </TR>
93 <TR BGCOLOR="white" CLASS="TableRowColor">
94 <TD WIDTH="20%"><B><A HREF="com/google/gson/package-summary.html">com.google.gson</A></B></TD>
95 <TD>This package provides the <A HREF="com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A> class to convert Json to Java and
96 vice-versa.</TD>
97 </TR>
98 <TR BGCOLOR="white" CLASS="TableRowColor">
99 <TD WIDTH="20%"><B><A HREF="com/google/gson/annotations/package-summary.html">com.google.gson.annotations</A></B></TD>
100 <TD>This package provides annotations that can be used with <A HREF="com/google/gson/Gson.html" title="class in com.google.gson"><CODE>Gson</CODE></A>.</TD>
101 </TR>
102 <TR BGCOLOR="white" CLASS="TableRowColor">
103 <TD WIDTH="20%"><B><A HREF="com/google/gson/reflect/package-summary.html">com.google.gson.reflect</A></B></TD>
104 <TD>This package provides utility classes for finding type information for generic types.</TD>
105 </TR>
106 <TR BGCOLOR="white" CLASS="TableRowColor">
107 <TD WIDTH="20%"><B><A HREF="com/google/gson/stream/package-summary.html">com.google.gson.stream</A></B></TD>
108 <TD>&nbsp;</TD>
109 </TR>
110 </TABLE>
111
112 <P>
113 &nbsp;<HR>
114
115
116 <!-- ======= START OF BOTTOM NAVBAR ====== -->
117 <A NAME="navbar_bottom"><!-- --></A>
118 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
119 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
120 <TR>
121 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
122 <A NAME="navbar_bottom_firstrow"><!-- --></A>
123 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
124 <TR ALIGN="center" VALIGN="top">
125 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Overview</B></FONT>&nbsp;</TD>
126 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
127 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
128 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
129 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
130 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
131 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
132 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
133 </TR>
134 </TABLE>
135 </TD>
136 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
137 </EM>
138 </TD>
139 </TR>
140
141 <TR>
142 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
143 &nbsp;PREV&nbsp;
144 &nbsp;NEXT</FONT></TD>
145 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
146 <A HREF="index.html?overview-summary.html" target="_top"><B>FRAMES</B></A> &nbsp;
147 &nbsp;<A HREF="overview-summary.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
148 &nbsp;<SCRIPT type="text/javascript">
149 <!--
150 if(window==top) {
151 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
152 }
153 //-->
154 </SCRIPT>
155 <NOSCRIPT>
156 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
157 </NOSCRIPT>
158
159
160 </FONT></TD>
161 </TR>
162 </TABLE>
163 <A NAME="skip-navbar_bottom"></A>
164 <!-- ======== END OF BOTTOM NAVBAR ======= -->
165
166 <HR>
167 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
168 </BODY>
169 </HTML>
+0
-196
gson/docs/javadocs/overview-tree.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Class Hierarchy (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Class Hierarchy (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="index.html?overview-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="overview-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H2>
84 Hierarchy For All Packages</H2>
85 </CENTER>
86 <DL>
87 <DT><B>Package Hierarchies:</B><DD><A HREF="com/google/gson/package-tree.html">com.google.gson</A>, <A HREF="com/google/gson/annotations/package-tree.html">com.google.gson.annotations</A>, <A HREF="com/google/gson/reflect/package-tree.html">com.google.gson.reflect</A>, <A HREF="com/google/gson/stream/package-tree.html">com.google.gson.stream</A></DL>
88 <HR>
89 <H2>
90 Class Hierarchy
91 </H2>
92 <UL>
93 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
94 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/FieldAttributes.html" title="class in com.google.gson"><B>FieldAttributes</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/Gson.html" title="class in com.google.gson"><B>Gson</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/GsonBuilder.html" title="class in com.google.gson"><B>GsonBuilder</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonElement.html" title="class in com.google.gson"><B>JsonElement</B></A><UL>
95 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonArray.html" title="class in com.google.gson"><B>JsonArray</B></A> (implements java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</A>&lt;T&gt;)
96 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonNull.html" title="class in com.google.gson"><B>JsonNull</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonObject.html" title="class in com.google.gson"><B>JsonObject</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonPrimitive.html" title="class in com.google.gson"><B>JsonPrimitive</B></A></UL>
97 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonParser.html" title="class in com.google.gson"><B>JsonParser</B></A><LI TYPE="circle">com.google.gson.stream.<A HREF="com/google/gson/stream/JsonReader.html" title="class in com.google.gson.stream"><B>JsonReader</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A>)
98 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonStreamParser.html" title="class in com.google.gson"><B>JsonStreamParser</B></A> (implements java.util.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</A>&lt;E&gt;)
99 <LI TYPE="circle">com.google.gson.stream.<A HREF="com/google/gson/stream/JsonWriter.html" title="class in com.google.gson.stream"><B>JsonWriter</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Closeable.html?is-external=true" title="class or interface in java.io">Closeable</A>, java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Flushable.html?is-external=true" title="class or interface in java.io">Flushable</A>)
100 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Throwable.html?is-external=true" title="class or interface in java.lang"><B>Throwable</B></A> (implements java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>)
101 <UL>
102 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Exception.html?is-external=true" title="class or interface in java.lang"><B>Exception</B></A><UL>
103 <LI TYPE="circle">java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io"><B>IOException</B></A><UL>
104 <LI TYPE="circle">com.google.gson.stream.<A HREF="com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream"><B>MalformedJsonException</B></A></UL>
105 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang"><B>RuntimeException</B></A><UL>
106 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonParseException.html" title="class in com.google.gson"><B>JsonParseException</B></A><UL>
107 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonIOException.html" title="class in com.google.gson"><B>JsonIOException</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonSyntaxException.html" title="class in com.google.gson"><B>JsonSyntaxException</B></A></UL>
108 </UL>
109 </UL>
110 </UL>
111 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/TypeAdapter.html" title="class in com.google.gson"><B>TypeAdapter</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.reflect.<A HREF="com/google/gson/reflect/TypeToken.html" title="class in com.google.gson.reflect"><B>TypeToken</B></A>&lt;T&gt;</UL>
112 </UL>
113 <H2>
114 Interface Hierarchy
115 </H2>
116 <UL>
117 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/ExclusionStrategy.html" title="interface in com.google.gson"><B>ExclusionStrategy</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson"><B>FieldNamingStrategy</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/InstanceCreator.html" title="interface in com.google.gson"><B>InstanceCreator</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonDeserializationContext.html" title="interface in com.google.gson"><B>JsonDeserializationContext</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonDeserializer.html" title="interface in com.google.gson"><B>JsonDeserializer</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonSerializationContext.html" title="interface in com.google.gson"><B>JsonSerializationContext</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/JsonSerializer.html" title="interface in com.google.gson"><B>JsonSerializer</B></A>&lt;T&gt;<LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/TypeAdapterFactory.html" title="interface in com.google.gson"><B>TypeAdapterFactory</B></A></UL>
118 <H2>
119 Annotation Type Hierarchy
120 </H2>
121 <UL>
122 <LI TYPE="circle">com.google.gson.annotations.<A HREF="com/google/gson/annotations/Until.html" title="annotation in com.google.gson.annotations"><B>Until</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
123 <LI TYPE="circle">com.google.gson.annotations.<A HREF="com/google/gson/annotations/Since.html" title="annotation in com.google.gson.annotations"><B>Since</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
124 <LI TYPE="circle">com.google.gson.annotations.<A HREF="com/google/gson/annotations/SerializedName.html" title="annotation in com.google.gson.annotations"><B>SerializedName</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
125 <LI TYPE="circle">com.google.gson.annotations.<A HREF="com/google/gson/annotations/JsonAdapter.html" title="annotation in com.google.gson.annotations"><B>JsonAdapter</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
126 <LI TYPE="circle">com.google.gson.annotations.<A HREF="com/google/gson/annotations/Expose.html" title="annotation in com.google.gson.annotations"><B>Expose</B></A> (implements java.lang.annotation.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/annotation/Annotation.html?is-external=true" title="class or interface in java.lang.annotation">Annotation</A>)
127 </UL>
128 <H2>
129 Enum Hierarchy
130 </H2>
131 <UL>
132 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang"><B>Object</B></A><UL>
133 <LI TYPE="circle">java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Enum.html?is-external=true" title="class or interface in java.lang"><B>Enum</B></A>&lt;E&gt; (implements java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Comparable.html?is-external=true" title="class or interface in java.lang">Comparable</A>&lt;T&gt;, java.io.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</A>)
134 <UL>
135 <LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/LongSerializationPolicy.html" title="enum in com.google.gson"><B>LongSerializationPolicy</B></A><LI TYPE="circle">com.google.gson.<A HREF="com/google/gson/FieldNamingPolicy.html" title="enum in com.google.gson"><B>FieldNamingPolicy</B></A> (implements com.google.gson.<A HREF="com/google/gson/FieldNamingStrategy.html" title="interface in com.google.gson">FieldNamingStrategy</A>)
136 <LI TYPE="circle">com.google.gson.stream.<A HREF="com/google/gson/stream/JsonToken.html" title="enum in com.google.gson.stream"><B>JsonToken</B></A></UL>
137 </UL>
138 </UL>
139 <HR>
140
141
142 <!-- ======= START OF BOTTOM NAVBAR ====== -->
143 <A NAME="navbar_bottom"><!-- --></A>
144 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
145 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
146 <TR>
147 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
148 <A NAME="navbar_bottom_firstrow"><!-- --></A>
149 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
150 <TR ALIGN="center" VALIGN="top">
151 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
152 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
153 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
154 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
155 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Tree</B></FONT>&nbsp;</TD>
156 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
157 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
158 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
159 </TR>
160 </TABLE>
161 </TD>
162 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
163 </EM>
164 </TD>
165 </TR>
166
167 <TR>
168 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
169 &nbsp;PREV&nbsp;
170 &nbsp;NEXT</FONT></TD>
171 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
172 <A HREF="index.html?overview-tree.html" target="_top"><B>FRAMES</B></A> &nbsp;
173 &nbsp;<A HREF="overview-tree.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
174 &nbsp;<SCRIPT type="text/javascript">
175 <!--
176 if(window==top) {
177 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
178 }
179 //-->
180 </SCRIPT>
181 <NOSCRIPT>
182 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
183 </NOSCRIPT>
184
185
186 </FONT></TD>
187 </TR>
188 </TABLE>
189 <A NAME="skip-navbar_bottom"></A>
190 <!-- ======== END OF BOTTOM NAVBAR ======= -->
191
192 <HR>
193 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
194 </BODY>
195 </HTML>
+0
-4
gson/docs/javadocs/package-list less more
0 com.google.gson
1 com.google.gson.annotations
2 com.google.gson.reflect
3 com.google.gson.stream
gson/docs/javadocs/resources/inherit.gif less more
Binary diff not shown
+0
-30
gson/docs/javadocs/script.js less more
0 function show(type)
1 {
2 count = 0;
3 for (var key in methods) {
4 var row = document.getElementById(key);
5 if ((methods[key] & type) != 0) {
6 row.style.display = '';
7 row.className = (count++ % 2) ? rowColor : altColor;
8 }
9 else
10 row.style.display = 'none';
11 }
12 updateTabs(type);
13 }
14
15 function updateTabs(type)
16 {
17 for (var value in tabs) {
18 var sNode = document.getElementById(tabs[value][0]);
19 var spanNode = sNode.firstChild;
20 if (value == type) {
21 sNode.className = activeTableTab;
22 spanNode.innerHTML = tabs[value][1];
23 }
24 else {
25 sNode.className = tableTab;
26 spanNode.innerHTML = "<a href=\"javascript:show("+ value + ");\">" + tabs[value][1] + "</a>";
27 }
28 }
29 }
+0
-217
gson/docs/javadocs/serialized-form.html less more
0 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
1 <!--NewPage-->
2 <HTML>
3 <HEAD>
4 <!-- Generated by javadoc (build 1.6.0_65) on Thu Nov 20 01:11:55 PST 2014 -->
5 <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
6 <TITLE>
7 Serialized Form (Gson 2.3.1 API)
8 </TITLE>
9
10 <META NAME="date" CONTENT="2014-11-20">
11
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="stylesheet.css" TITLE="Style">
13
14 <SCRIPT type="text/javascript">
15 function windowTitle()
16 {
17 if (location.href.indexOf('is-external=true') == -1) {
18 parent.document.title="Serialized Form (Gson 2.3.1 API)";
19 }
20 }
21 </SCRIPT>
22 <NOSCRIPT>
23 </NOSCRIPT>
24
25 </HEAD>
26
27 <BODY BGCOLOR="white" onload="windowTitle();">
28 <HR>
29
30
31 <!-- ========= START OF TOP NAVBAR ======= -->
32 <A NAME="navbar_top"><!-- --></A>
33 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35 <TR>
36 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37 <A NAME="navbar_top_firstrow"><!-- --></A>
38 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39 <TR ALIGN="center" VALIGN="top">
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
42 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
43 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
44 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48 </TR>
49 </TABLE>
50 </TD>
51 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52 </EM>
53 </TD>
54 </TR>
55
56 <TR>
57 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58 &nbsp;PREV&nbsp;
59 &nbsp;NEXT</FONT></TD>
60 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61 <A HREF="index.html?serialized-form.html" target="_top"><B>FRAMES</B></A> &nbsp;
62 &nbsp;<A HREF="serialized-form.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
63 &nbsp;<SCRIPT type="text/javascript">
64 <!--
65 if(window==top) {
66 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
67 }
68 //-->
69 </SCRIPT>
70 <NOSCRIPT>
71 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
72 </NOSCRIPT>
73
74
75 </FONT></TD>
76 </TR>
77 </TABLE>
78 <A NAME="skip-navbar_top"></A>
79 <!-- ========= END OF TOP NAVBAR ========= -->
80
81 <HR>
82 <CENTER>
83 <H1>
84 Serialized Form</H1>
85 </CENTER>
86 <HR SIZE="4" NOSHADE>
87
88 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
89 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
90 <TH ALIGN="center"><FONT SIZE="+2">
91 <B>Package</B> <B>com.google.gson</B></FONT></TH>
92 </TR>
93 </TABLE>
94
95 <P>
96 <A NAME="com.google.gson.JsonIOException"><!-- --></A>
97 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
98 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
99 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
100 <B>Class <A HREF="com/google/gson/JsonIOException.html" title="class in com.google.gson">com.google.gson.JsonIOException</A> extends <A HREF="com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A> implements Serializable</B></FONT></TH>
101 </TR>
102 </TABLE>
103
104 <P>
105 <B>serialVersionUID:&nbsp;</B>1L
106
107 <P>
108
109 <P>
110 <A NAME="com.google.gson.JsonParseException"><!-- --></A>
111 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
112 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
113 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
114 <B>Class <A HREF="com/google/gson/JsonParseException.html" title="class in com.google.gson">com.google.gson.JsonParseException</A> extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/RuntimeException.html?is-external=true" title="class or interface in java.lang">RuntimeException</A> implements Serializable</B></FONT></TH>
115 </TR>
116 </TABLE>
117
118 <P>
119 <B>serialVersionUID:&nbsp;</B>-4086729973971783390L
120
121 <P>
122
123 <P>
124 <A NAME="com.google.gson.JsonSyntaxException"><!-- --></A>
125 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
126 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
127 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
128 <B>Class <A HREF="com/google/gson/JsonSyntaxException.html" title="class in com.google.gson">com.google.gson.JsonSyntaxException</A> extends <A HREF="com/google/gson/JsonParseException.html" title="class in com.google.gson">JsonParseException</A> implements Serializable</B></FONT></TH>
129 </TR>
130 </TABLE>
131
132 <P>
133 <B>serialVersionUID:&nbsp;</B>1L
134
135 <P>
136 <HR SIZE="4" NOSHADE>
137
138 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
139 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
140 <TH ALIGN="center"><FONT SIZE="+2">
141 <B>Package</B> <B>com.google.gson.stream</B></FONT></TH>
142 </TR>
143 </TABLE>
144
145 <P>
146 <A NAME="com.google.gson.stream.MalformedJsonException"><!-- --></A>
147 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
148 <TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
149 <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
150 <B>Class <A HREF="com/google/gson/stream/MalformedJsonException.html" title="class in com.google.gson.stream">com.google.gson.stream.MalformedJsonException</A> extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A> implements Serializable</B></FONT></TH>
151 </TR>
152 </TABLE>
153
154 <P>
155 <B>serialVersionUID:&nbsp;</B>1L
156
157 <P>
158
159 <P>
160 <HR>
161
162
163 <!-- ======= START OF BOTTOM NAVBAR ====== -->
164 <A NAME="navbar_bottom"><!-- --></A>
165 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
166 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
167 <TR>
168 <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
169 <A NAME="navbar_bottom_firstrow"><!-- --></A>
170 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
171 <TR ALIGN="center" VALIGN="top">
172 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
173 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Package</FONT>&nbsp;</TD>
174 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Class</FONT>&nbsp;</TD>
175 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <FONT CLASS="NavBarFont1">Use</FONT>&nbsp;</TD>
176 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="overview-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
177 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
178 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
179 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
180 </TR>
181 </TABLE>
182 </TD>
183 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
184 </EM>
185 </TD>
186 </TR>
187
188 <TR>
189 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
190 &nbsp;PREV&nbsp;
191 &nbsp;NEXT</FONT></TD>
192 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
193 <A HREF="index.html?serialized-form.html" target="_top"><B>FRAMES</B></A> &nbsp;
194 &nbsp;<A HREF="serialized-form.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
195 &nbsp;<SCRIPT type="text/javascript">
196 <!--
197 if(window==top) {
198 document.writeln('<A HREF="allclasses-noframe.html"><B>All Classes</B></A>');
199 }
200 //-->
201 </SCRIPT>
202 <NOSCRIPT>
203 <A HREF="allclasses-noframe.html"><B>All Classes</B></A>
204 </NOSCRIPT>
205
206
207 </FONT></TD>
208 </TR>
209 </TABLE>
210 <A NAME="skip-navbar_bottom"></A>
211 <!-- ======== END OF BOTTOM NAVBAR ======= -->
212
213 <HR>
214 Copyright &#169; 2008&#x2013;2014 <a href="http://www.google.com">Google, Inc.</a>. All rights reserved.
215 </BODY>
216 </HTML>
+0
-29
gson/docs/javadocs/stylesheet.css less more
0 /* Javadoc style sheet */
1
2 /* Define colors, fonts and other style attributes here to override the defaults */
3
4 /* Page background color */
5 body { background-color: #FFFFFF; color:#000000 }
6
7 /* Headings */
8 h1 { font-size: 145% }
9
10 /* Table colors */
11 .TableHeadingColor { background: #CCCCFF; color:#000000 } /* Dark mauve */
12 .TableSubHeadingColor { background: #EEEEFF; color:#000000 } /* Light mauve */
13 .TableRowColor { background: #FFFFFF; color:#000000 } /* White */
14
15 /* Font used in left-hand frame lists */
16 .FrameTitleFont { font-size: 100%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
17 .FrameHeadingFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
18 .FrameItemFont { font-size: 90%; font-family: Helvetica, Arial, sans-serif; color:#000000 }
19
20 /* Navigation bar fonts and colors */
21 .NavBarCell1 { background-color:#EEEEFF; color:#000000} /* Light mauve */
22 .NavBarCell1Rev { background-color:#00008B; color:#FFFFFF} /* Dark Blue */
23 .NavBarFont1 { font-family: Arial, Helvetica, sans-serif; color:#000000;color:#000000;}
24 .NavBarFont1Rev { font-family: Arial, Helvetica, sans-serif; color:#FFFFFF;color:#FFFFFF;}
25
26 .NavBarCell2 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF; color:#000000}
27 .NavBarCell3 { font-family: Arial, Helvetica, sans-serif; background-color:#FFFFFF; color:#000000}
28
33 <parent>
44 <groupId>com.google.code.gson</groupId>
55 <artifactId>gson-parent</artifactId>
6 <version>2.8.6</version>
6 <version>2.8.7</version>
77 </parent>
88
99 <artifactId>gson</artifactId>
2626 <includePackageNames>com.google.gson</includePackageNames>
2727 <excludePackageNames>com.google.gson.internal:com.google.gson.internal.bind</excludePackageNames>
2828 <links>
29 <link>http://docs.oracle.com/javase/6/docs/api/</link>
29 <link>https://docs.oracle.com/javase/6/docs/api/</link>
3030 </links>
3131 </configuration>
3232 </plugin>
3333 <plugin>
3434 <groupId>biz.aQute.bnd</groupId>
3535 <artifactId>bnd-maven-plugin</artifactId>
36 <version>4.0.0</version>
36 <version>5.3.0</version>
3737 <executions>
3838 <execution>
3939 <goals>
5050 <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
5151 </archive>
5252 </configuration>
53 </plugin>
54 <plugin>
55 <groupId>org.apache.felix</groupId>
56 <artifactId>maven-bundle-plugin</artifactId>
5753 </plugin>
5854 <plugin>
5955 <groupId>org.codehaus.mojo</groupId>
4545 *
4646 * <p><strong>Excludes fields and objects based on a particular annotation:</strong>
4747 * <pre class="code">
48 * public &#64interface FooAnnotation {
48 * public &#64;interface FooAnnotation {
4949 * // some implementation here
5050 * }
5151 *
52 * // Excludes any field (or class) that is tagged with an "&#64FooAnnotation"
52 * // Excludes any field (or class) that is tagged with an "&#64;FooAnnotation"
5353 * private static class FooAnnotationExclusionStrategy implements ExclusionStrategy {
5454 * public boolean shouldSkipClass(Class&lt;?&gt; clazz) {
5555 * return clazz.getAnnotation(FooAnnotation.class) != null;
4343 * Using this naming policy with Gson will ensure that the first "letter" of the Java
4444 * field name is capitalized when serialized to its JSON form.
4545 *
46 * <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
46 * <p>Here's a few examples of the form "Java Field Name" ---&gt; "JSON Field Name":</p>
4747 * <ul>
48 * <li>someFieldName ---> SomeFieldName</li>
49 * <li>_someFieldName ---> _SomeFieldName</li>
48 * <li>someFieldName ---&gt; SomeFieldName</li>
49 * <li>_someFieldName ---&gt; _SomeFieldName</li>
5050 * </ul>
5151 */
5252 UPPER_CAMEL_CASE() {
6060 * field name is capitalized when serialized to its JSON form and the words will be
6161 * separated by a space.
6262 *
63 * <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
63 * <p>Here's a few examples of the form "Java Field Name" ---&gt; "JSON Field Name":</p>
6464 * <ul>
65 * <li>someFieldName ---> Some Field Name</li>
66 * <li>_someFieldName ---> _Some Field Name</li>
65 * <li>someFieldName ---&gt; Some Field Name</li>
66 * <li>_someFieldName ---&gt; _Some Field Name</li>
6767 * </ul>
6868 *
6969 * @since 1.4
7878 * Using this naming policy with Gson will modify the Java Field name from its camel cased
7979 * form to a lower case field name where each word is separated by an underscore (_).
8080 *
81 * <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
81 * <p>Here's a few examples of the form "Java Field Name" ---&gt; "JSON Field Name":</p>
8282 * <ul>
83 * <li>someFieldName ---> some_field_name</li>
84 * <li>_someFieldName ---> _some_field_name</li>
85 * <li>aStringField ---> a_string_field</li>
86 * <li>aURL ---> a_u_r_l</li>
83 * <li>someFieldName ---&gt; some_field_name</li>
84 * <li>_someFieldName ---&gt; _some_field_name</li>
85 * <li>aStringField ---&gt; a_string_field</li>
86 * <li>aURL ---&gt; a_u_r_l</li>
8787 * </ul>
8888 */
8989 LOWER_CASE_WITH_UNDERSCORES() {
9696 * Using this naming policy with Gson will modify the Java Field name from its camel cased
9797 * form to a lower case field name where each word is separated by a dash (-).
9898 *
99 * <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
99 * <p>Here's a few examples of the form "Java Field Name" ---&gt; "JSON Field Name":</p>
100100 * <ul>
101 * <li>someFieldName ---> some-field-name</li>
102 * <li>_someFieldName ---> _some-field-name</li>
103 * <li>aStringField ---> a-string-field</li>
104 * <li>aURL ---> a-u-r-l</li>
101 * <li>someFieldName ---&gt; some-field-name</li>
102 * <li>_someFieldName ---&gt; _some-field-name</li>
103 * <li>aStringField ---&gt; a-string-field</li>
104 * <li>aURL ---&gt; a-u-r-l</li>
105105 * </ul>
106106 * Using dashes in JavaScript is not recommended since dash is also used for a minus sign in
107107 * expressions. This requires that a field named with dashes is always accessed as a quoted
119119 * Using this naming policy with Gson will modify the Java Field name from its camel cased
120120 * form to a lower case field name where each word is separated by a dot (.).
121121 *
122 * <p>Here's a few examples of the form "Java Field Name" ---> "JSON Field Name":</p>
122 * <p>Here's a few examples of the form "Java Field Name" ---&gt; "JSON Field Name":</p>
123123 * <ul>
124 * <li>someFieldName ---> some.field.name</li>
125 * <li>_someFieldName ---> _some.field.name</li>
126 * <li>aStringField ---> a.string.field</li>
127 * <li>aURL ---> a.u.r.l</li>
124 * <li>someFieldName ---&gt; some.field.name</li>
125 * <li>_someFieldName ---&gt; _some.field.name</li>
126 * <li>aStringField ---&gt; a.string.field</li>
127 * <li>aURL ---&gt; a.u.r.l</li>
128128 * </ul>
129129 * Using dots in JavaScript is not recommended since dot is also used for a member sign in
130130 * expressions. This requires that a field named with dots is always accessed as a quoted
170170 public int size() {
171171 return elements.size();
172172 }
173
174 /**
175 * Returns true if the array is empty
176 *
177 * @return true if the array is empty
178 */
179 public boolean isEmpty() {
180 return elements.isEmpty();
181 }
173182
174183 /**
175184 * Returns an iterator to navigate the elements of the array. Since the array is an ordered list,
2828
2929 /**
3030 * A streaming parser that allows reading of multiple {@link JsonElement}s from the specified reader
31 * asynchronously.
32 *
31 * asynchronously. The JSON data is parsed in lenient mode, see also
32 * {@link JsonReader#setLenient(boolean)}.
33 *
3334 * <p>This class is conditionally thread-safe (see Item 70, Effective Java second edition). To
3435 * properly use this class across multiple threads, you will need to add some external
3536 * synchronization. For example:
7172 }
7273
7374 /**
74 * Returns the next available {@link JsonElement} on the reader. Null if none available.
75 *
76 * @return the next available {@link JsonElement} on the reader. Null if none available.
77 * @throws JsonParseException if the incoming stream is malformed JSON.
75 * Returns the next available {@link JsonElement} on the reader. Throws a
76 * {@link NoSuchElementException} if no element is available.
77 *
78 * @return the next available {@code JsonElement} on the reader.
79 * @throws JsonSyntaxException if the incoming stream is malformed JSON.
80 * @throws NoSuchElementException if no {@code JsonElement} is available.
7881 * @since 1.4
7982 */
8083 public JsonElement next() throws JsonParseException {
9699 /**
97100 * Returns true if a {@link JsonElement} is available on the input for consumption
98101 * @return true if a {@link JsonElement} is available on the input, false otherwise
102 * @throws JsonSyntaxException if the incoming stream is malformed JSON.
99103 * @since 1.4
100104 */
101105 public boolean hasNext() {
3333 * <p>Here is an example of how this annotation is meant to be used:
3434 * <p><pre>
3535 * public class User {
36 * &#64Expose private String firstName;
37 * &#64Expose(serialize = false) private String lastName;
38 * &#64Expose (serialize = false, deserialize = false) private String emailAddress;
36 * &#64;Expose private String firstName;
37 * &#64;Expose(serialize = false) private String lastName;
38 * &#64;Expose (serialize = false, deserialize = false) private String emailAddress;
3939 * private String password;
4040 * }
4141 * </pre></p>
3030 *
3131 * <p>Here is an example of how this annotation is used:</p>
3232 * <pre>
33 * &#64JsonAdapter(UserJsonAdapter.class)
33 * &#64;JsonAdapter(UserJsonAdapter.class)
3434 * public class User {
3535 * public final String firstName, lastName;
3636 * private User(String firstName, String lastName) {
3939 * }
4040 * }
4141 * public class UserJsonAdapter extends TypeAdapter&lt;User&gt; {
42 * &#64Override public void write(JsonWriter out, User user) throws IOException {
42 * &#64;Override public void write(JsonWriter out, User user) throws IOException {
4343 * // implement write: combine firstName and lastName into name
4444 * out.beginObject();
4545 * out.name("name");
4747 * out.endObject();
4848 * // implement the write method
4949 * }
50 * &#64Override public User read(JsonReader in) throws IOException {
50 * &#64;Override public User read(JsonReader in) throws IOException {
5151 * // implement read: split name into firstName and lastName
5252 * in.beginObject();
5353 * in.nextName();
5858 * }
5959 * </pre>
6060 *
61 * Since User class specified UserJsonAdapter.class in &#64JsonAdapter annotation, it
61 * Since User class specified UserJsonAdapter.class in &#64;JsonAdapter annotation, it
6262 * will automatically be invoked to serialize/deserialize User instances. <br>
6363 *
6464 * <p> Here is an example of how to apply this annotation to a field.
6565 * <pre>
6666 * private static final class Gadget {
67 * &#64JsonAdapter(UserJsonAdapter2.class)
67 * &#64;JsonAdapter(UserJsonAdapter2.class)
6868 * final User user;
6969 * Gadget(User user) {
7070 * this.user = user;
3434 * <p>Here is an example of how this annotation is meant to be used:</p>
3535 * <pre>
3636 * public class MyClass {
37 * &#64SerializedName("name") String a;
38 * &#64SerializedName(value="name1", alternate={"name2", "name3"}) String b;
37 * &#64;SerializedName("name") String a;
38 * &#64;SerializedName(value="name1", alternate={"name2", "name3"}) String b;
3939 * String c;
4040 *
4141 * public MyClass(String a, String b, String c) {
3535 * public class User {
3636 * private String firstName;
3737 * private String lastName;
38 * &#64Since(1.0) private String emailAddress;
39 * &#64Since(1.0) private String password;
40 * &#64Since(1.1) private Address address;
38 * &#64;Since(1.0) private String emailAddress;
39 * &#64;Since(1.0) private String password;
40 * &#64;Since(1.1) private Address address;
4141 * }
4242 * </pre>
4343 *
3737 * public class User {
3838 * private String firstName;
3939 * private String lastName;
40 * &#64Until(1.1) private String emailAddress;
41 * &#64Until(1.1) private String password;
40 * &#64;Until(1.1) private String emailAddress;
41 * &#64;Until(1.1) private String password;
4242 * }
4343 * </pre>
4444 *
129129 }
130130
131131 @Override public JsonWriter name(String name) throws IOException {
132 if (name == null) {
133 throw new NullPointerException("name == null");
134 }
132135 if (stack.isEmpty() || pendingName != null) {
133136 throw new IllegalStateException();
134137 }
169169 * precision loss, extremely large values should be written and read as strings
170170 * in JSON.
171171 *
172 * <a name="nonexecuteprefix"/><h3>Non-Execute Prefix</h3>
172 * <a id="nonexecuteprefix"/><h3>Non-Execute Prefix</h3>
173173 * Web servers that serve private data using JSON may be vulnerable to <a
174174 * href="http://en.wikipedia.org/wiki/JSON#Cross-site_request_forgery">Cross-site
175175 * request forgery</a> attacks. In such an attack, a malicious site gains access
188188 * @since 1.6
189189 */
190190 public class JsonReader implements Closeable {
191 /** The only non-execute prefix this parser permits */
192 private static final char[] NON_EXECUTE_PREFIX = ")]}'\n".toCharArray();
193191 private static final long MIN_INCOMPLETE_INTEGER = Long.MIN_VALUE / 10;
194192
195193 private static final int PEEKED_NONE = 0;
15711569 nextNonWhitespace(true);
15721570 pos--;
15731571
1574 if (pos + NON_EXECUTE_PREFIX.length > limit && !fillBuffer(NON_EXECUTE_PREFIX.length)) {
1572 int p = pos;
1573 if (p + 5 > limit && !fillBuffer(5)) {
15751574 return;
15761575 }
15771576
1578 for (int i = 0; i < NON_EXECUTE_PREFIX.length; i++) {
1579 if (buffer[pos + i] != NON_EXECUTE_PREFIX[i]) {
1580 return; // not a security token!
1581 }
1577 char[] buf = buffer;
1578 if(buf[p] != ')' || buf[p + 1] != ']' || buf[p + 2] != '}' || buf[p + 3] != '\'' || buf[p + 4] != '\n') {
1579 return; // not a security token!
15821580 }
15831581
15841582 // we consumed a security token!
1585 pos += NON_EXECUTE_PREFIX.length;
1583 pos += 5;
15861584 }
15871585
15881586 static {
107107 assertTrue(json.isString());
108108 assertEquals('z', json.getAsCharacter());
109109 assertEquals("z", json.getAsString());
110
111 json = new JsonPrimitive(true);
112 assertEquals("true", json.getAsString());
110113 }
111114
112115 public void testExponential() throws Exception {
119119 assertEquals(JsonNull.INSTANCE, writer.get());
120120 }
121121
122 public void testBeginArray() throws Exception {
123 JsonTreeWriter writer = new JsonTreeWriter();
124 assertEquals(writer, writer.beginArray());
125 }
126
127 public void testBeginObject() throws Exception {
128 JsonTreeWriter writer = new JsonTreeWriter();
129 assertEquals(writer, writer.beginObject());
130 }
131
132 public void testValueString() throws Exception {
133 JsonTreeWriter writer = new JsonTreeWriter();
134 String n = "as";
135 assertEquals(writer, writer.value(n));
136 }
137
138 public void testBoolValue() throws Exception {
139 JsonTreeWriter writer = new JsonTreeWriter();
140 boolean bool = true;
141 assertEquals(writer, writer.value(bool));
142 }
143
144 public void testBoolMaisValue() throws Exception {
145 JsonTreeWriter writer = new JsonTreeWriter();
146 Boolean bool = true;
147 assertEquals(writer, writer.value(bool));
148 }
149
122150 public void testLenientNansAndInfinities() throws IOException {
123151 JsonTreeWriter writer = new JsonTreeWriter();
124152 writer.setLenient(true);
0 package com.google.gson.internal.bind.util;
1
2 import org.junit.Rule;
3 import org.junit.Test;
4 import org.junit.rules.ExpectedException;
5
6 import java.text.ParseException;
7 import java.text.ParsePosition;
8 import java.util.*;
9
10 import static org.junit.Assert.assertEquals;
11
12 public class ISO8601UtilsTest {
13
14 @Rule
15 public final ExpectedException exception = ExpectedException.none();
16
17 private static TimeZone utcTimeZone() {
18 return TimeZone.getTimeZone("UTC");
19 }
20
21 private static GregorianCalendar createUtcCalendar() {
22 TimeZone utc = utcTimeZone();
23 GregorianCalendar calendar = new GregorianCalendar(utc);
24 // Calendar was created with current time, must clear it
25 calendar.clear();
26 return calendar;
27 }
28
29 @Test
30 public void testDateFormatString() {
31 GregorianCalendar calendar = new GregorianCalendar(utcTimeZone(), Locale.US);
32 // Calendar was created with current time, must clear it
33 calendar.clear();
34 calendar.set(2018, Calendar.JUNE, 25);
35 Date date = calendar.getTime();
36 String dateStr = ISO8601Utils.format(date);
37 String expectedDate = "2018-06-25";
38 assertEquals(expectedDate, dateStr.substring(0, expectedDate.length()));
39 }
40
41 @Test
42 public void testDateFormatWithMilliseconds() {
43 long time = 1530209176870L;
44 Date date = new Date(time);
45 String dateStr = ISO8601Utils.format(date, true);
46 String expectedDate = "2018-06-28T18:06:16.870Z";
47 assertEquals(expectedDate, dateStr);
48 }
49
50 @Test
51 public void testDateFormatWithTimezone() {
52 long time = 1530209176870L;
53 Date date = new Date(time);
54 String dateStr = ISO8601Utils.format(date, true, TimeZone.getTimeZone("Brazil/East"));
55 String expectedDate = "2018-06-28T15:06:16.870-03:00";
56 assertEquals(expectedDate, dateStr);
57 }
58
59 @Test
60 public void testDateParseWithDefaultTimezone() throws ParseException {
61 String dateStr = "2018-06-25";
62 Date date = ISO8601Utils.parse(dateStr, new ParsePosition(0));
63 Date expectedDate = new GregorianCalendar(2018, Calendar.JUNE, 25).getTime();
64 assertEquals(expectedDate, date);
65 }
66
67 @Test
68 public void testDateParseWithTimezone() throws ParseException {
69 String dateStr = "2018-06-25T00:00:00-03:00";
70 Date date = ISO8601Utils.parse(dateStr, new ParsePosition(0));
71 GregorianCalendar calendar = createUtcCalendar();
72 calendar.set(2018, Calendar.JUNE, 25, 3, 0);
73 Date expectedDate = calendar.getTime();
74 assertEquals(expectedDate, date);
75 }
76
77 @Test
78 public void testDateParseSpecialTimezone() throws ParseException {
79 String dateStr = "2018-06-25T00:02:00-02:58";
80 Date date = ISO8601Utils.parse(dateStr, new ParsePosition(0));
81 GregorianCalendar calendar = createUtcCalendar();
82 calendar.set(2018, Calendar.JUNE, 25, 3, 0);
83 Date expectedDate = calendar.getTime();
84 assertEquals(expectedDate, date);
85 }
86
87 @Test
88 public void testDateParseInvalidTime() throws ParseException {
89 String dateStr = "2018-06-25T61:60:62-03:00";
90 exception.expect(ParseException.class);
91 ISO8601Utils.parse(dateStr, new ParsePosition(0));
92 }
93 }
5050 <dependency>
5151 <groupId>junit</groupId>
5252 <artifactId>junit</artifactId>
53 <version>3.8.2</version>
53 <version>4.13.1</version>
5454 <scope>test</scope>
5555 </dependency>
5656 </dependencies>
1010
1111 <groupId>com.google.code.gson</groupId>
1212 <artifactId>gson-parent</artifactId>
13 <version>2.8.6</version>
13 <version>2.8.7</version>
1414 <packaging>pom</packaging>
1515
1616 <name>Gson Parent</name>
3030 <url>https://github.com/google/gson/</url>
3131 <connection>scm:git:https://github.com/google/gson.git</connection>
3232 <developerConnection>scm:git:git@github.com:google/gson.git</developerConnection>
33 <tag>gson-parent-2.8.6</tag>
33 <tag>gson-parent-2.8.7</tag>
3434 </scm>
3535
3636 <issueManagement>
4141 <licenses>
4242 <license>
4343 <name>Apache 2.0</name>
44 <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
44 <url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
4545 </license>
4646 </licenses>
4747
5050 <dependency>
5151 <groupId>junit</groupId>
5252 <artifactId>junit</artifactId>
53 <version>4.12</version>
53 <version>4.13.2</version>
5454 <scope>test</scope>
5555 </dependency>
5656 </dependencies>
9696 <plugin>
9797 <groupId>org.apache.maven.plugins</groupId>
9898 <artifactId>maven-javadoc-plugin</artifactId>
99 <version>2.10.4</version>
99 <version>3.3.0</version>
100100 </plugin>
101101 <plugin>
102102 <groupId>org.apache.maven.plugins</groupId>
105105 <plugin>
106106 <groupId>org.apache.felix</groupId>
107107 <artifactId>maven-bundle-plugin</artifactId>
108 <version>3.3.0</version>
108 <version>5.1.2</version>
109109 <inherited>true</inherited>
110110 </plugin>
111111 </plugins>
118118 <dependencies>
119119 <dependency>
120120 <groupId>org.apache.maven.scm</groupId>
121 <artifactId>maven-scm-api</artifactId>
122 <version>1.11.2</version>
123 </dependency>
124 <dependency>
125 <groupId>org.apache.maven.scm</groupId>
121126 <artifactId>maven-scm-provider-gitexe</artifactId>
122 <version>1.9.5</version>
127 <version>1.11.2</version>
123128 </dependency>
124129 </dependencies>
125130 <configuration>
7575 <dependency>
7676 <groupId>junit</groupId>
7777 <artifactId>junit</artifactId>
78 <version>4.12</version>
78 <version>4.13.1</version>
7979 <scope>test</scope>
8080 </dependency>
8181