Bases: ABC
Bases: Parser
, ABC
Bases: BlockParser
Bases: BlockParser
Bases: BlockParser
, ABC
Bases: NestedBlockParser
Bases: NestedBlockParser
Bases: NestedBlockParser
Bases: NestedBlockParser
Bases: NestedBlockParser
Bases: Parser
Bases: Parser
Bases: SectionParser
Bases: SectionParser
Bases: SectionParser
Bases: SectionParser
Bases: SectionParser
Bases: SectionParser
Bases: SectionParser
Parses the given source into a model represented as an AST.
How to use the model is explained more thoroughly in the general documentation of the robot.parsing
module.
source – The source where to read the data. Can be a path to a source file as a string or as pathlib.Path
object, an already opened file object, or Unicode text containing the date directly. Source files must be UTF-8 encoded.
data_only – When False
(default), returns all tokens. When set to True
, omits separators, comments, continuation markers, and other non-data tokens. Model like this cannot be saved back to file system.
curdir – Directory where the source file exists. This path is used to set the value of the built-in ${CURDIR}
variable during parsing. When not given, the variable is left as-is. Should only be given only if the model will be executed afterward. If the model is saved back to disk, resolving ${CURDIR}
is typically not a good idea.
lang – Additional languages to be supported during parsing. Can be a string matching any of the supported language codes or names, an initialized Language
subclass, a list containing such strings or instances, or a Languages
instance.
Use get_resource_model()
or get_init_model()
when parsing resource or suite initialization files, respectively.
Parses the given source into a resource file model.
Same as get_model()
otherwise, but the source is considered to be a resource file. This affects, for example, what settings are valid.
Parses the given source into an init file model.
Same as get_model()
otherwise, but the source is considered to be a suite initialization file. This affects, for example, what settings are valid.
Bases: ModelVisitor
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4