Lines Matching refs:PrettyPrinter
23 Construct :class:`PrettyPrinter` objects explicitly if you need to adjust the
33 .. class:: PrettyPrinter(indent=1, width=80, depth=None, stream=None, *, \
36 Construct a :class:`PrettyPrinter` instance. This constructor understands
39 :meth:`write` method. If not specified, the :class:`PrettyPrinter` adopts
59 >>> pp = pprint.PrettyPrinter(indent=4)
67 >>> pp = pprint.PrettyPrinter(width=41, compact=True)
75 >>> pp = pprint.PrettyPrinter(depth=6)
85 *width*, *depth* and *compact* will be passed to the :class:`PrettyPrinter`
100 to the :class:`PrettyPrinter` constructor as formatting parameters.
149 PrettyPrinter Objects
152 :class:`PrettyPrinter` instances have the following methods:
155 .. method:: PrettyPrinter.pformat(object)
158 options passed to the :class:`PrettyPrinter` constructor.
161 .. method:: PrettyPrinter.pprint(object)
168 more efficient since new :class:`PrettyPrinter` objects don't need to be
172 .. method:: PrettyPrinter.isreadable(object)
179 :class:`PrettyPrinter` is set and the object is deeper than allowed, this
183 .. method:: PrettyPrinter.isrecursive(object)
192 .. method:: PrettyPrinter.format(object, context, maxlevels, level)