def dump(self, indent='<STR_LIT>', depth=<NUM_LIT:0>, full=True):
out = []<EOL>NL = '<STR_LIT:\n>'<EOL>out.append( indent+_ustr(self.asList()) )<EOL>if full:<EOL><INDENT>if self.haskeys():<EOL><INDENT>items = sorted((str(k), v) for k,v in self.items())<EOL>for k,v in items:<EOL><INDENT>if out:<EOL><INDENT>out.append(NL)<EOL><DEDENT>out.append( "<STR_LIT>" % (indent,('<STR_LIT:U+0020>'*depth), k) )<EOL>if isinstance(v,ParseResults):<EOL><INDENT>if v:<EOL><INDENT>out.append( v.dump(indent,depth+<NUM_LIT:1>) )<EOL><DEDENT>else:<EOL><INDENT>out.append(_ustr(v))<EOL><DEDENT><DEDENT>else:<EOL><INDENT>out.append(repr(v))<EOL><DEDENT><DEDENT><DEDENT>elif any(isinstance(vv,ParseResults) for vv in self):<EOL><INDENT>v = self<EOL>for i,vv in enumerate(v):<EOL><INDENT>if isinstance(vv,ParseResults):<EOL><INDENT>out.append("<STR_LIT>" % (indent,('<STR_LIT:U+0020>'*(depth)),i,indent,('<STR_LIT:U+0020>'*(depth+<NUM_LIT:1>)),vv.dump(indent,depth+<NUM_LIT:1>) ))<EOL><DEDENT>else:<EOL><INDENT>out.append("<STR_LIT>" % (indent,('<STR_LIT:U+0020>'*(depth)),i,indent,('<STR_LIT:U+0020>'*(depth+<NUM_LIT:1>)),_ustr(vv)))<EOL><DEDENT><DEDENT><DEDENT><DEDENT>return "<STR_LIT>".join(out)<EOL>
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.parseString('12/31/1999')
    print(result.dump())

prints::

    ['12', '/', '31', '/', '1999']
    - day: 1999
    - month: 31
    - year: 12