Code: Select all
json.toVars(jsonObj[,prefix]): jsonArray of keys
json.fromVars(jsonArray/List[,prefix]): jsonObj
The prefix is optional. json.toVars adds the prefix to the key values in json object. Error is returned if prefix+key is not a valid variable format. The returned jsonArray is the list of keys of the object + the prefix if included.
json.fromVar takes an array of keys (like the one returned by json.toVars) or a string list. The prefix is optional and removes the matching prefix from the keys in the jsonArray or list. This returns a json object of the variables as keys with their values.