2.7. parsers¶
2.7.1. JsonParser suite¶
Used to parse JSON files or JSON data strings to dictionaries
-
class
resources.libraries.python.parsers.JsonParser.
JsonParser
¶ Bases:
object
Parses JSON data string or files containing JSON data strings
-
static
parse_data
(json_data)¶ Return list parsed from JSON data string.
Translates JSON data into list of values/dictionaries/lists.
- Parameters
json_data (str) – Data in JSON format.
- Returns
JSON data parsed as python list.
- Return type
list
-
static
parse_file
(json_file)¶ Return list parsed from file containing JSON string.
Translates JSON data found in file into list of values/dictionaries/lists.
- Parameters
json_file (str) – File with JSON type data.
- Returns
JSON data parsed as python list.
- Return type
list
-
static