MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / doc

Function doc

tools/python-3.11.9-amd64/Lib/pydoc.py:1863–1878  ·  view source on GitHub ↗

Display text documentation, given an object or a path to an object.

(thing, title='Python Library Documentation: %s', forceload=0,
        output=None, is_cli=False)

Source from the content-addressed store, hash-verified

1861 return title % desc + '\n\n' + renderer.document(object, name)
1862
1863def doc(thing, title='Python Library Documentation: %s', forceload=0,
1864 output=None, is_cli=False):
1865 """Display text documentation, given an object or a path to an object."""
1866 if output is None:
1867 try:
1868 pager(render_doc(thing, title, forceload))
1869 except ImportError as exc:
1870 if is_cli:
1871 raise
1872 print(exc)
1873 else:
1874 try:
1875 s = render_doc(thing, title, forceload, plaintext)
1876 except ImportError as exc:
1877 s = str(exc)
1878 output.write(s)
1879
1880def writedoc(thing, forceload=0):
1881 """Write HTML documentation to a file in the current directory."""

Callers 1

helpMethod · 0.70

Calls 5

pagerFunction · 0.85
render_docFunction · 0.85
strFunction · 0.85
printFunction · 0.50
writeMethod · 0.45

Tested by

no test coverage detected