summaryrefslogtreecommitdiff
path: root/docs/class-simple_json.JSONDecoder.html
blob: e8c4bc4ac725bc95d3375d3ddf7b5c2089bc6edd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<HTML>
  
  <HEAD><META CONTENT="text/html; charset=utf-8" HTTP-EQUIV="Content-Type">
    <TITLE>simple_json.JSONDecoder -- Simple JSON &amp;lt;&lt;a class="reference" href="http://json.org">http://json.org&lt;/a>&amp;gt; decoder</TITLE>
    <LINK HREF="layout.css" TYPE="text/css" REL="stylesheet">
    
  </HEAD>
  <BODY>
    <DIV ID="page">
      
    <DIV ID="top-nav">
        <H1 ID="doc-title">
        <A HREF="index.html" REL="index">simple_json 1.1</A></H1>
        <DIV CLASS="online-navigation">
          <A HREF="index.html" REL="index">index</A>
          <SPAN ID="nav-docs">
            
          </SPAN>
          
          
          <BR>
          
          
          
          <A HREF="module-simple_json.html" TITLE="simple_json reference">
            simple_json
          </A>
          
            
            <A HREF="class-simple_json.JSONDecoder.html">details</A>
            
            <A HREF="class-simple_json.JSONDecoder-index.html">
              tree
            </A>
            
          
        </DIV>
    </DIV>
    
    <DIV ID="main-content">
  
  <H1 CLASS="pudge-member-page-heading">
    <TT>JSONDecoder</TT>
  </H1>
  <H4 CLASS="pudge-member-page-subheading">
    Simple JSON &lt;<A HREF="http://json.org" CLASS="reference">http://json.org</A>> decoder
  </H4>
  <P CLASS="pudge-member-parent-link">
    <SMALL>
    The JSONDecoder class is accessible via the
    <A HREF="module-simple_json.html">
      <TT>simple_json</TT>
    </A> module.
    </SMALL>
  </P>
  <DIV ID="pudge-section-nav">
  <UL>
    <LI>
      
      <SPAN CLASS="pudge-missing-section-link">
        Attributes
      </SPAN>
    </LI>
    <LI>
      <A HREF="#methods" CLASS="pudge-section-link">
        Methods (1)
      </A>
      
    </LI>
    
    <LI>
      <A HREF="simple_json/decoder.py.html?f=196&amp;l=254#196" CLASS="pudge-section-link">
        Source
      </A>
    </LI>
  </UL>
  </DIV>
  <DIV STYLE="clear: left">
  </DIV>
  <DIV CLASS="rst pudge-module-doc">
    <P>Performs the following translations in decoding:</P>
<TABLE BORDER="1" CLASS="docutils">
<COLGROUP>
<COL WIDTH="44%">

<COL WIDTH="56%">

</COLGROUP>
<THEAD VALIGN="bottom">
<TR>
<TH CLASS="head">JSON</TH>
<TH CLASS="head">Python</TH>
</TR>
</THEAD>
<TBODY VALIGN="top">
<TR>
<TD>object</TD>
<TD>dict</TD>
</TR>
<TR>
<TD>array</TD>
<TD>list</TD>
</TR>
<TR>
<TD>string</TD>
<TD>unicode</TD>
</TR>
<TR>
<TD>number (int)</TD>
<TD>int, long</TD>
</TR>
<TR>
<TD>number (real)</TD>
<TD>float</TD>
</TR>
<TR>
<TD>true</TD>
<TD>True</TD>
</TR>
<TR>
<TD>false</TD>
<TD>False</TD>
</TR>
<TR>
<TD>null</TD>
<TD>None</TD>
</TR>
</TBODY>
</TABLE>
<P>It also understands <TT CLASS="docutils literal"><SPAN CLASS="pre">NaN</SPAN></TT>, <TT CLASS="docutils literal"><SPAN CLASS="pre">Infinity</SPAN></TT>, and <TT CLASS="docutils literal"><SPAN CLASS="pre">-Infinity</SPAN></TT> as
their corresponding <TT CLASS="docutils literal"><SPAN CLASS="pre">float</SPAN></TT> values, which is outside the JSON spec.</P>
  </DIV>
  
  <HR>
  
  
  
  
    <A NAME="methods">
  
  
    </A>
    <H2>Methods</H2>
    <DIV CLASS="pudge-member routine alias">
    <A NAME="__init__">
    </A>
    <H4 CLASS="pudge-member-name">
    <SPAN CLASS="prefix">f</SPAN>
      <TT>
      <A HREF="class-simple_json.JSONDecoder.html#__init__" CLASS="pudge-obj-link">__init__</A>(self, encoding=None)</TT>
      <A HREF="simple_json/decoder.py.html?f=225&amp;l=227#225" TITLE="View Source">...</A>
    </H4>
    <DIV CLASS="pudge-section rst">
      
    
    
  
    </DIV>
  </DIV>
    
  
  
  <P>
    <SMALL>
    
    
    See 
    <A HREF="simple_json/decoder.py.html?f=196&amp;l=254#196" TITLE="simple_json/decoder.py:196">the source</A>
    for more information.
    </SMALL>
  </P>
</DIV>
    
    <DIV ID="footer">
      
      <P ID="pudge">
        Built with
        <A HREF="http://lesscode.org/projects/pudge/">
          Pudge/0.1</A>
      </P>
      
    </DIV>
    </DIV>
  </BODY>
</HTML>