PageRenderTime 70ms CodeModel.GetById 58ms app.highlight 9ms RepoModel.GetById 1ms app.codeStats 0ms

/docs/com/google/maps/extras/arcgislink/json/JSON.html

http://gmaps-utility-library-flash.googlecode.com/
HTML | 158 lines | 148 code | 1 blank | 9 comment | 0 complexity | 8303078ba26b59818b2960746480f721 MD5 | raw file
  1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2<html>
  3<head>
  4<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5<link rel="stylesheet" href="../../../../../../style.css" type="text/css" media="screen">
  6<link rel="stylesheet" href="../../../../../../print.css" type="text/css" media="print">
  7<meta content="JSON,com.google.maps.extras.arcgislink.json.JSON,decode,encode" name="keywords">
  8<title>com.google.maps.extras.arcgislink.json.JSON</title>
  9</head>
 10<body>
 11<script type="text/javascript" language="javascript" src="../../../../../../asdoc.js"></script><script type="text/javascript" language="javascript" src="../../../../../../cookies.js"></script><script type="text/javascript" language="javascript">
 12<!--
 13				asdocTitle = 'JSON - API Documentation';
 14				var baseRef = '../../../../../../';
 15				window.onload = configPage;
 16			--></script>
 17<table style="display:none" id="titleTable" cellspacing="0" cellpadding="0" class="titleTable">
 18<tr>
 19<td align="left" class="titleTableTitle">API Documentation</td><td align="right" class="titleTableTopNav"><a onclick="loadClassListFrame('../../../../../../all-classes.html')" href="../../../../../../package-summary.html">All&nbsp;Packages</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../../../../all-classes.html')" href="../../../../../../class-summary.html">All&nbsp;Classes</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../../../../../index-list.html')" href="../../../../../../all-index-A.html">Index</a>&nbsp;|&nbsp;<a href="../../../../../../index.html?com/google/maps/extras/arcgislink/json/JSON.html&amp;com/google/maps/extras/arcgislink/json/class-list.html" id="framesLink1">Frames</a><a onclick="parent.location=document.location" href="" style="display:none" id="noFramesLink1">No&nbsp;Frames</a></td><td rowspan="3" align="right" class="titleTableLogo"><img alt="Adobe Logo" title="Adobe Logo" class="logoImage" src="../../../../../../images/logo.jpg"></td>
 20</tr>
 21<tr class="titleTableRow2">
 22<td align="left" id="subTitle" class="titleTableSubTitle">Class&nbsp;JSON</td><td align="right" id="subNav" class="titleTableSubNav"><a href="#methodSummary">Methods</a></td>
 23</tr>
 24<tr class="titleTableRow3">
 25<td colspan="2">&nbsp;</td>
 26</tr>
 27</table>
 28<script type="text/javascript" language="javascript">
 29<!--
 30if (!isEclipse() || window.name != ECLIPSE_FRAME_NAME) {titleBar_setSubTitle("Class JSON"); titleBar_setSubNav(false,false,false,false,false,false,true,false,false,false,false,false,false,false);}
 31--></script>
 32<div class="MainContent">
 33<table cellspacing="0" cellpadding="0" class="classHeaderTable">
 34<tr>
 35<td class="classHeaderTableLabel">Package</td><td><a onclick="javascript:loadClassListFrame('class-list.html')" href="package-detail.html">com.google.maps.extras.arcgislink.json</a></td>
 36</tr>
 37<tr>
 38<td class="classHeaderTableLabel">Class</td><td class="classSignature">public class JSON</td>
 39</tr>
 40</table>
 41<p></p>
 42  Modified from http://code.google.com/p/as3corelib/: This class provides encoding and decoding of the JSON format.
 43    Example usage:
 44  <code>
 45    // create a JSON string from an internal object
 46    JSON.encode( myObject );
 47     // read a JSON string into an internal object
 48   var myObject:Object = JSON.decode( jsonString );
 49  </code>
 50  <p></p>
 51<br>
 52<hr>
 53</div>
 54<a name="methodSummary"></a>
 55<div class="summarySection">
 56<div class="summaryTableTitle">Public Methods</div>
 57<table id="summaryTableMethod" class="summaryTable " cellpadding="3" cellspacing="0">
 58<tr>
 59<th>&nbsp;</th><th colspan="2">Method</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
 60</tr>
 61<tr class="">
 62<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
 63<div class="summarySignature">
 64<a class="signatureLink" href="#decode()">decode</a>(s:String, strict:Boolean = true):*</div>
 65<div class="summaryTableDescription">[static]
 66   Decodes a JSON string into a native object.</div>
 67</td><td class="summaryTableOwnerCol">JSON</td>
 68</tr>
 69<tr class="">
 70<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
 71<div class="summarySignature">
 72<a class="signatureLink" href="#encode()">encode</a>(o:Object):String</div>
 73<div class="summaryTableDescription">[static]
 74   Encodes a object into a JSON string.</div>
 75</td><td class="summaryTableOwnerCol">JSON</td>
 76</tr>
 77</table>
 78</div>
 79<script type="text/javascript" language="javascript">
 80<!--
 81showHideInherited();
 82--></script>
 83<div class="MainContent">
 84<a name="methodDetail"></a>
 85<div class="detailSectionHeader">Method detail</div>
 86<a name="decode()"></a>
 87<table cellspacing="0" cellpadding="0" class="detailHeader">
 88<tr>
 89<td class="detailHeaderName">decode</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td>
 90</tr>
 91</table>
 92<div class="detailBody">
 93<code>public static function decode(s:String, strict:Boolean = true):*</code><p>
 94   Decodes a JSON string into a native object.
 95   
 96   </p><span class="label">Parameters</span>
 97<table border="0" cellspacing="0" cellpadding="0">
 98<tr>
 99<td width="20px"></td><td><code><span class="label">s</span>:String</code> &mdash; The JSON string representing the object
100   </td>
101</tr>
102<tr>
103<td class="paramSpacer">&nbsp;</td>
104</tr>
105<tr>
106<td width="20px"></td><td><code><span class="label">strict</span>:Boolean</code> (default = <code>true</code>)<code></code> &mdash; Flag indicating if the decoder should strictly adhere
107     to the JSON standard or not.  The default of <code>true</code>
108     throws errors if the format does not match the JSON syntax exactly.
109     Pass <code>false</code> to allow for non-properly-formatted JSON
110     strings to be decoded with more leniancy.
111   </td>
112</tr>
113</table>
114<p></p>
115<span class="label">Returns</span>
116<table border="0" cellspacing="0" cellpadding="0">
117<tr>
118<td width="20"></td><td><code>*</code> &mdash; A native object as specified by s
119   </td>
120</tr>
121</table>
122</div>
123<a name="encode()"></a>
124<table cellspacing="0" cellpadding="0" class="detailHeader">
125<tr>
126<td class="detailHeaderName">encode</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
127</tr>
128</table>
129<div class="detailBody">
130<code>public static function encode(o:Object):String</code><p>
131   Encodes a object into a JSON string.
132      </p><span class="label">Parameters</span>
133<table border="0" cellspacing="0" cellpadding="0">
134<tr>
135<td width="20px"></td><td><code><span class="label">o</span>:Object</code> &mdash; The object to create a JSON string for
136   </td>
137</tr>
138</table>
139<p></p>
140<span class="label">Returns</span>
141<table border="0" cellspacing="0" cellpadding="0">
142<tr>
143<td width="20"></td><td><code>String</code> &mdash; the JSON string representing o
144   </td>
145</tr>
146</table>
147</div>
148<br>
149<br>
150<hr>
151<br>
152<p></p>
153<center class="copyright"> 
154</center>
155</div>
156</body>
157</html>
158<!-- -->