The JS object is serialized as a JSON object with the following code:
- /**
- * JSON Parsing class
- Method
- * Decodes a JSON string into an object that is recognized by the page
- * @param {string} JSON the JSON String
- * @return {Object} The resulting object
- * Object o = jsonutil.decode (JSON);
- *
- * Serializing a JS object as a JSON string
- * @param {Mixed} o the variable to decode
- * @return {string} The JSON string
- * String json = Jsonutil.encode (o);
- */
- var jsonutil;
- if (! Jsonutil) {
- Jsonutil = {};
- }
- Jsonutil.decode = function (JSON) {
- try {
- Return eval ("\u0028" + json + ' \u0029 ');
- } catch (Exception) {
- Return eval ("\u0075\u006e\u0064\u0065\u0066\u0069\u006e\u0065\u0064");
- }
- };
- Jsonutil.encode = (function () {
- var $ =!! {}.hasownproperty, _ = function ($) {
- Return $ < 10? "0" + $: $
- }, A = {
- "\b": "\\b",
- "\ T": "\\t",
- "\ n": "\\n",
- "\f": "\\f",
- ' \ r ': ' \ R ',
- "\"" : "\\\"",
- "\\" : "\\\\"
- };
- Return (function (C) {
- if (typeof c = = "\u0075\u006e\u0064\u0065\u0066\u0069\u006e\u0065\u0064" c = = null)
- return "NULL";
- else if (Object.prototype.toString.call (C) = = "\u005b\u006f\u0062\u006a\u0065\u0063\u0074\u0020\u0041\u0072\u0072 \u0061\u0079\u005d ") {
- var B = ["\u005b"], G, E, D = C.length, F;
- for (E = 0; E < D; E = 1) {
- F = C[e];
- Switch (typeof F) {
- Case "\u0075\u006e\u0064\u0065\u0066\u0069\u006e\u0065\u0064":
- Case "\u0066\u0075\u006e\u0063\u0074\u0069\u006f\u006e":
- Case "\u0075\u006e\u006b\u006e\u006f\u0077\u006e":
- Break
- Default:
- if (G)
- B.push ("\u002c");
- B.push (F = = null?) "Null": This.encode (F));
- G = True
- }
- }
- B.push ("\u005d");
- Return B.join ("")
- else if ((Object.prototype.toString.call (C) = = "\u005b\u006f\u0062\u006a\u0065\u0063\u0074\u0020\u0044\u0061\ u0074\u0065\u005d "))
- Return "" "+ c.getfullyear () +"-"+ _ (C.getmonth () + 1) +"-"+ _ (C.getdate ()) +" T "+ _ (c.gethours ()) +": "+ _ (C.GETMI Nutes ()) + ":" + _ (C.getseconds ()) + "" ";
- else if (typeof C = = "\u0073\u0074\u0072\u0069\u006e\u0067") {
- if (/["\\\x00-\x1f]/.test (C))
- Return "\" + c.replace (/([\x00-\x1f\\ "])/g, function (B, _) {
- var $ = a[_];
- if ($)
- return $;
- $ = _.charcodeat ();
- Return "\\u00" + math.floor ($/). ToString ($%). ToString (16)
- }) + "\"";
- return "\" "+ C +" \ ""
- else if (typeof C = "\u006e\u0075\u006d\u0062\u0065\u0072")
- return Isfinite (C)? String (C): "NULL";
- else if (typeof C = "\u0062\u006f\u006f\u006c\u0065\u0061\u006e")
- Return String (C);
- else {
- B = ["\u007b"], G, E, F;
- For (E in C)
- if (!$ c.hasownproperty (E)) {
- F = C[e];
- if (F = = null)
- Continue
- Switch (typeof F) {
- Case "\u0075\u006e\u0064\u0065\u0066\u0069\u006e\u0065\u0064":
- Case "\u0066\u0075\u006e\u0063\u0074\u0069\u006f\u006e":
- Case "\u0075\u006e\u006b\u006e\u006f\u0077\u006e":
- Break
- Default:
- if (G)
- B.push ("\u002c");
- B.push (This.encode (E), "\u003a", This.encode (F));
- G = True
- }
- }
- B.push ("\u007d");
- Return B.join ("")
- }
- })
- })();
- Window. Jsonutil = Jsonutil;