class_docstr: Structured parse results, to provide multiple means of access to
  the parsed data:
  
  - as a list (``len(results)``)
  - by list index (``results[0], results[1]``, etc.)
  - by attribute (``results.<results_name>`` - see :class:`ParserElement.set_results_name`)
  
  Example::
  
      integer = Word(nums)
      date_str = (integer.set_results_name("year") + '/'
                  + integer.set_results_name("month") + '/'
                  + integer.set_results_name("day"))
      # equivalent form:
      # date_str = (integer("year") + '/'
      #             + integer("month") + '/'
      #             + integer("day"))
  
      # parse_string returns a ParseResults object
      result = date_str.parse_string("1999/12/31")
  
      def test(s, fn=repr):
          print(f"{s} -> {fn(eval(s))}")
      test("list(result)")
      test("result[0]")
      test("result['month']")
      test("result.day")
      test("'month' in result")
      test("'minutes' in result")
      test("result.dump()", str)
  
  prints::
  
      list(result) -> ['1999', '/', '12', '/', '31']
      result[0] -> '1999'
      result['month'] -> '12'
      result.day -> '31'
      'month' in result -> True
      'minutes' in result -> False
      result.dump() -> ['1999', '/', '12', '/', '31']
      - day: '31'
      - month: '12'
      - year: '1999'
class_docstr_tok: ["Structured","parse","results",",","to","provide","multiple","means","of","access","to","the","parsed","data",":","-","as","a","list","(","``","len","(","results",")","``",")","-","by","list","index","(","``","results","[","0","]",",","results","[","1","]","``",",","etc",".",")","-","by","attribute","(","``","results.","<","results_name",">","``","-","see",":","class",":","`","ParserElement.set_results_name","`",")","Example",":",":","integer","=","Word","(","nums",")","date_str","=","(","integer.set_results_name","(","``","year","''",")","+","'\/'","+","integer.set_results_name","(","``","month","''",")","+","'\/'","+","integer.set_results_name","(","``","day","''",")",")","#","equivalent","form",":","#","date_str","=","(","integer","(","``","year","''",")","+","'\/'","#","+","integer","(","``","month","''",")","+","'\/'","#","+","integer","(","``","day","''",")",")","#","parse_string","returns","a","ParseResults","object","result","=","date_str.parse_string","(","``","1999\/12\/31","''",")","def","test","(","s",",","fn=repr",")",":","print","(","f","''","{","s","}","-",">","{","fn","(","eval","(","s",")",")","}","''",")","test","(","``","list","(","result",")","''",")","test","(","``","result","[","0","]","''",")","test","(","``","result","[","'month","'","]","''",")","test","(","``","result.day","''",")","test","(","``","'month","'","in","result","''",")","test","(","``","'minutes","'","in","result","''",")","test","(","``","result.dump","(",")","''",",","str",")","prints",":",":","list","(","result",")","-",">","[","'1999","'",",","'\/","'",",","'12","'",",","'\/","'",",","'31","'","]","result","[","0","]","-",">","'1999'","result","[","'month","'","]","-",">","'12'","result.day","-",">","'31'","'month","'","in","result","-",">","True","'minutes","'","in","result","-",">","False","result.dump","(",")","-",">","[","'1999","'",",","'\/","'",",","'12","'",",","'\/","'",",","'31","'","]","-","day",":","'31'","-","month",":","'12'","-","year",":","'1999","'"]
docstr: Diagnostic method for listing out the contents of
  a :class:`ParseResults`. Accepts an optional ``indent`` argument so
  that this string can be embedded in a nested display of other data.
  
  Example::
  
      integer = Word(nums)
      date_str = integer("year") + '/' + integer("month") + '/' + integer("day")
  
      result = date_str.parse_string('1999/12/31')
      print(result.dump())
  
  prints::
  
      ['1999', '/', '12', '/', '31']
      - day: '31'
      - month: '12'
      - year: '1999'
docstr_tok: ["Diagnostic","method","for","listing","out","the","contents","of","a",":","class",":","`","ParseResults","`",".","Accepts","an","optional","``","indent","``","argument","so","that","this","string","can","be","embedded","in","a","nested","display","of","other","data",".","Example",":",":","integer","=","Word","(","nums",")","date_str","=","integer","(","``","year","''",")","+","'\/","'","+","integer","(","``","month","''",")","+","'\/","'","+","integer","(","``","day","''",")","result","=","date_str.parse_string","(","'1999\/12\/31","'",")","print","(","result.dump","(",")",")","prints",":",":","[","'1999","'",",","'\/","'",",","'12","'",",","'\/","'",",","'31","'","]","-","day",":","'31'","-","month",":","'12'","-","year",":","'1999","'"]
code: def dump(
      self, indent="", full=True, include_list=True, _depth=0
  ) -> str:
      """
      Diagnostic method for listing out the contents of
      a :class:`ParseResults`. Accepts an optional ``indent`` argument so
      that this string can be embedded in a nested display of other data.
  
      Example::
  
          integer = Word(nums)
          date_str = integer("year") + '/' + integer("month") + '/' + integer("day")
  
          result = date_str.parse_string('1999/12/31')
          print(result.dump())
  
      prints::
  
          ['1999', '/', '12', '/', '31']
          - day: '31'
          - month: '12'
          - year: '1999'
      """
      out = []
      NL = "\n"
      out.append(indent + str(self.as_list()) if include_list else "")
  
      if full:
          if self.haskeys():
              items = sorted((str(k), v) for k, v in self.items())
              for k, v in items:
                  if out:
                      out.append(NL)
                  out.append(f"{indent}{('  ' * _depth)}- {k}: ")
                  if isinstance(v, ParseResults):
                      if v:
                          out.append(
                              v.dump(
                                  indent=indent,
                                  full=full,
                                  include_list=include_list,
                                  _depth=_depth + 1,
                              )
                          )
                      else:
                          out.append(str(v))
                  else:
                      out.append(repr(v))
          if any(isinstance(vv, ParseResults) for vv in self):
              v = self
              for i, vv in enumerate(v):
                  if isinstance(vv, ParseResults):
                      out.append(
                          "\n{}{}[{}]:\n{}{}{}".format(
                              indent,
                              ("  " * (_depth)),
                              i,
                              indent,
                              ("  " * (_depth + 1)),
                              vv.dump(
                                  indent=indent,
                                  full=full,
                                  include_list=include_list,
                                  _depth=_depth + 1,
                              ),
                          )
                      )
                  else:
                      out.append(
                          "\n%s%s[%d]:\n%s%s%s"
                          % (
                              indent,
                              ("  " * (_depth)),
                              i,
                              indent,
                              ("  " * (_depth + 1)),
                              str(vv),
                          )
                      )
  
      return "".join(out)
  
imports: from collections.abc import MutableMapping, Mapping, MutableSequence, Iterator, Sequence, Container
  import pprint
  from typing import Tuple, Any, Dict, Set, List
label_desc: Use image node_id 33 for calling the ParseResults obj's underlying member method code with example usage: obj.dump(indent, full, include_list, _depth) and returns: str