|
1 | 1 | # objinspect |
2 | | - |
| 2 | + |
3 | 3 | [](https://github.com/zigai/objinspect/actions/workflows/tests.yml) |
4 | 4 | [](https://objinspect.readthedocs.io/en/latest/?badge=latest) |
5 | 5 | [](https://badge.fury.io/py/objinspect) |
6 | 6 |  |
7 | 7 | [](https://pepy.tech/project/objinspect) |
8 | 8 | [](https://github.com/zigai/objinspect/blob/main/LICENSE) |
9 | 9 |
|
10 | | -`objinspect` is a high-level wrapper around Python's built-in `inspect` module. |
| 10 | +`objinspect` is a high-level wrapper around Python's built-in `inspect` module. |
11 | 11 | It provides a simple interface for examining Python functions and classes. |
12 | 12 |
|
13 | 13 | ## Features |
@@ -35,15 +35,15 @@ Function(name='pow', parameters=2, description='Return x**y (x to the power of y |
35 | 35 |
|
36 | 36 | >>> inspect(math.pow).dict |
37 | 37 | { |
38 | | - 'name': 'pow', |
| 38 | + 'name': 'pow', |
39 | 39 | 'parameters': [ |
40 | | - {'name': 'x', 'kind': <_ParameterKind.POSITIONAL_ONLY: 0>, 'type': <class 'inspect._empty'>, 'default': <class 'inspect._empty'>, 'description': None}, |
41 | | - {'name': 'y', 'kind': <_ParameterKind.POSITIONAL_ONLY: 0>, 'type': <class 'inspect._empty'>, 'default': <class 'inspect._empty'>, 'description': None}], |
| 40 | + {'name': 'x', 'kind': <_ParameterKind.POSITIONAL_ONLY: 0>, 'type': <class 'inspect._empty'>, 'default': <class 'inspect._empty'>, 'description': None}, |
| 41 | + {'name': 'y', 'kind': <_ParameterKind.POSITIONAL_ONLY: 0>, 'type': <class 'inspect._empty'>, 'default': <class 'inspect._empty'>, 'description': None}], |
42 | 42 | 'docstring': 'Return x**y (x to the power of y).' |
43 | 43 | } |
44 | | - |
| 44 | + |
45 | 45 | >>> inspect(inspect) |
46 | | -Function(name='inspect', parameters=7, description='Inspects an object and returns a structured representation of its attributes and methods.') |
| 46 | +Function(name='inspect', parameters=8, description='Inspects an object and returns a structured representation of its attributes and methods.') |
47 | 47 | ``` |
48 | 48 | ### prettydir |
49 | 49 |  |
|
0 commit comments