This module offers high-level API for parsing text into hierarchical data structures, in particular, JSON. Parsers like this can be used to create abstract syntax trees of compatible inputs. For convenience and scriptability any parser is expected to be able to dump its AST as JSON.
Abstract interface for parsers.
The interface is meant to be suitable for the implementation of the plainbox dev parse command. It offers a simple API for parsing strings and getting JSON in result.
Parse the specified text and return a parser-specific native Abstract Syntax Tree that represents the input.
Any exception gets logged and causes None to be returned.
PlugIn wrapping a parser function.
Useful for wrapping checkbox parser functions.
Parse the specified text and return a parser-specific native Abstract Syntax Tree that represents the input.
Any exception gets logged and causes None to be returned.