loads the GP object from a JSON string
775589
def fromJSON(value):
        
        j = json.loads(value)
        v = GPLong()
        if "defaultValue" in j:
            v.value = j['defaultValue']
        else:
            v.value = j['value']
        if 'paramName' in j:
            v.paramName = j['paramName']
        elif 'name' in j:
            v.paramName = j['name']
        return v
802891
def from_json(self, json_string):
        

        obj = json.loads(json_string)
        self.from_dict(obj['groups'], obj['data'])

        return self
220055
def _loads(s):
    
    if isinstance(s, bytes):
        s = s.decode("utf-8")
    return pyjson.loads(s)
522795
def load(cls, tree_path):
        """"""
        with open(tree_path) as f:
            tree_dict = json.load(f)

        return cls.from_dict(tree_dict)
487368
private void loadJsonResource(JSONObject json, Properties properties, Object name)
                                throws JSONException {
    Iterator<?> keys = json.keys();
    while (keys.hasNext()) {
      Object obj = keys.next();
      if (!(obj instanceof String)) {
        LOG.warn("Object not instance of string : " + obj + " skipping");
        continue;
      }
      String key = (String) obj;
      // can't have . in thrift fields so we represent . with _
      String keyUnderscoresToDots = key.replace("_", ".");  
      // actual _ are represented as __ in thrift schema
      keyUnderscoresToDots = keyUnderscoresToDots.replace("..", "_");
      if (!json.isNull(key)) {
        Object value = json.get(key);
        String stringVal = "";
        if (value instanceof String) {
          stringVal = (String)value;
        } else if (value instanceof Integer) {
            stringVal = new Integer((Integer)value).toString();
        } else if (value instanceof Long) {
            stringVal = new Long((Long)value).toString();
        } else if (value instanceof Double) {
            stringVal = new Double((Double)value).toString();
        } else if (value instanceof Boolean) {
            stringVal = new Boolean((Boolean)value).toString();
        } else if (value instanceof JSONObject) {
            loadJsonResource((JSONObject)value, properties, name);
            continue;
        } else {
            LOG.warn("unsupported value in json object: " + value);
        }
        if (!finalParameters.contains(keyUnderscoresToDots)) {
          properties.setProperty(keyUnderscoresToDots, stringVal);
          updatingResource.put(keyUnderscoresToDots, name.toString());
    	} else {
    	    LOG.warn(name+":a attempt to override final parameter: "+
                     keyUnderscoresToDots+";  Ignoring.");
    	}
      } 
    }
  }
988600
def loadJson(self, data):
        """"""
        if not isinstance(data, dict):
            data = json.loads(data)
        self.__dict__.update(data)
        self.inflate() # restore objects from str values
        #if self.ports:  self._gotPorts = True
        return self
867970
def from_json(cls, json):
        """"""
        obj = cls(name=json['name'],
                  code=json['code'],
                  numeric_code=json['numeric_code'],
                  symbol=json['symbol'],
                  exponent=json['exponent'],
                  entities=json['entities'],
                  withdrawal_date=json['withdrawal_date'],
                  subunits=json['subunits'])
        return obj
81766
def from_json_str(cls, json_str):
    
    return cls.from_json(json.loads(json_str, cls=JsonDecoder))
201850
def fromJSON(value):
        
        j = json.loads(value)
        v = GPFeatureRecordSetLayer()
        if "defaultValue" in j:
            v.value = j['defaultValue']
        else:
            v.value = j['value']
        if 'paramName' in j:
            v.paramName = j['paramName']
        elif 'name' in j:
            v.paramName = j['name']
        return v
1344773
function loadJSON (path, callback) {
  var xobj = new XMLHttpRequest();
  xobj.overrideMimeType('application/json');
  xobj.open('GET', path, true);
  xobj.onreadystatechange = function () {
    if (xobj.readyState === 4 && xobj.status === 200) {
      callback(xobj.responseText);
    }
  };
  xobj.send(null);
}
943521
def load_json(filename, gzip_mode=False):
    ''''''

    open_file = open
    if gzip_mode:
        open_file = gzip.open

    try:
        with open_file(filename, 'rt') as fh:
            data = json.load(fh)
            data = convert_unicode_2_utf8(data)
            return data
    except AttributeError:
        # Python-2.6
        fh = open_file(filename, 'rt')
        data = json.load(fh)
        fh.close()
        data = convert_unicode_2_utf8(data)
        return data
743720
def _fromJSON(cls, jsonobject):
        
        newInstance = cls(None, None)
        newInstance.__dict__.update(jsonobject)
        return newInstance
116185
def __load_json(self, stream):
        

        import json

        try:
            return json.loads(stream)
        except ValueError as e:
            cause = "invalid json format. %s" % str(e)
        raise InvalidFormatError(cause=cause)
1098724
def from_json(cls, string):
        """"""
        obj = json.loads(string)
        return cls(obj['regexp'], obj['files'])
1148128
def from_json(self, data):
        
        try:
            d = json.loads(data)
        except ValueError:
            raise InvalidMessageException()
        self.from_dict(d)
349657
def from_json(cls, string):
        
        exp_dict = json_to_data(string)
        version = exp_dict.get('version', 0)
        if version == 0:
            return cls.from_dict(exp_dict)
        elif version == 1:
            return cls.from_dict(exp_dict)
        else:
            raise ValueError("Version %d not supported" % version)
182387
def load_json(self):
        
        try:
            self.request.arguments = json.loads(self.request.body)
        except ValueError:
            msg = "Could not decode JSON: %s" % self.request.body
            self.logger.debug(msg)
            self.raise_error(400, msg)