MCPcopy Create free account
hub / github.com/davisking/dlib / print_element

Function print_element

docs/docs/python/generate_dlib_listing.py:5–14  ·  view source on GitHub ↗
(name, fc, ff, fconstants)

Source from the content-addressed store, hash-verified

3import inspect
4
5def print_element(name, fc, ff, fconstants):
6 isclass = inspect.isclass(eval(name))
7 ismodule = inspect.ismodule(eval(name))
8 isroutine = inspect.isroutine(eval(name))
9 if (isclass):
10 print("* :class:`{0}`".format(name), file=fc)
11 elif (isroutine):
12 print("* :func:`{0}`".format(name), file=ff)
13 elif (not ismodule):
14 print("* :const:`{0}`".format(name), file=fconstants)
15
16def make_listing_files():
17

Callers 1

make_listing_filesFunction · 0.85

Calls 3

evalFunction · 0.85
printFunction · 0.50
formatMethod · 0.45

Tested by

no test coverage detected