diff options
author | Paul McGuire <ptmcg@austin.rr.com> | 2019-06-05 22:34:45 -0500 |
---|---|---|
committer | Paul McGuire <ptmcg@austin.rr.com> | 2019-06-05 22:34:45 -0500 |
commit | 07f4d4dd27a859c16397fbb2c4d3bb5dde79d323 (patch) | |
tree | caeb4c1bdd8d916f5dccd9f208a17b250080cfa5 /pyparsing.py | |
parent | 8a57884ce0fe80b14d1a2b082103515f8dcbab04 (diff) | |
download | pyparsing-git-07f4d4dd27a859c16397fbb2c4d3bb5dde79d323.tar.gz |
Add better help directing to ParseResults as the return type for ParserElement.parseString
Diffstat (limited to 'pyparsing.py')
-rw-r--r-- | pyparsing.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/pyparsing.py b/pyparsing.py index b0f391e..2a20daa 100644 --- a/pyparsing.py +++ b/pyparsing.py @@ -87,6 +87,8 @@ classes inherit from. Use the docstrings for examples of how to: more complex ones - associate names with your parsed results using :class:`ParserElement.setResultsName` + - access the parsed data, which is returned as a :class:`ParseResults` + object - find some helpful expression short-cuts like :class:`delimitedList` and :class:`oneOf` - find more useful common expressions in the :class:`pyparsing_common` @@ -94,7 +96,7 @@ classes inherit from. Use the docstrings for examples of how to: """ __version__ = "2.4.1" -__versionTime__ = "26 May 2019 14:04 UTC" +__versionTime__ = "06 Jun 2019 03:33 UTC" __author__ = "Paul McGuire <ptmcg@users.sourceforge.net>" import string @@ -1783,6 +1785,10 @@ class ParserElement(object): This is the main interface to the client code, once the complete expression has been built. + Returns the parsed data as a :class:`ParseResults` object, which may be + accessed as a list, or as a dict or object with attributes if the given parser + includes results names. + If you want the grammar to require that the entire input string be successfully parsed, then set ``parseAll`` to True (equivalent to ending the grammar with ``StringEnd()``). |