inspect class final

Module definition for the Python module inspect. This is hand-crafted and not generated. Thus it only contains a subset of the actual module.

Inheritance
  • Object
  • PythonObjectInterface<PythonFfiDelegate<Object?>, Object?>
  • PythonObject
  • PythonModule
  • inspect

Constructors

inspect.from(PythonModuleInterface<PythonFfiDelegate<Object?>, Object?> moduleDelegate)
Wraps a Python object with the inspect module definition.

Properties

finalizer → Finalizer<(PythonFfiDelegate<Object?>, Object?)>
The finalizer for the python object. Gets invoked when the object is no longer accessible to the program.
finalinherited
hashCode → int
The hash code for this object.
no setterinherited
initializer → Initializer<PythonFfiDelegate<Object?>, Object?>
The initializer for the python object. Gets invoked at the start of the constructor.
finalinherited
platform → PythonFfiDelegate<Object?>
Gets the platform that this object is associated with.
no setterinherited
reference → Object?
Gets the reference to the python object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

cleandoc(String doc) → String
Clean up indentation from docstrings that are indented to line up with blocks of code.
debugDump() → void
Dumps the python object to the console.
inherited
getAttribute<T extends Object?>(String attributeName) → T
Gets the attribute with the given name.
inherited
getAttributeOrNull<T extends Object?>(String attributeName) → T?
Gets the attribute with the given name or null if it does not exist.
inherited
getAttributeRaw<T extends PythonObjectInterface<PythonFfiDelegate<Object?>, Object?>>(String attributeName) → T
Gets the attribute with the given name.
inherited
getClass(String className, List<Object?> args, [Map<String, Object?>? kwargs]) → PythonClassInterface<PythonFfiDelegate<Object?>, Object?>
Gets a class from the module.
inherited
getdoc(Object? object) → String?
Get the documentation string for an object, cleaned up with cleandoc. If the documentation string for an object is not provided and the object is a class, a method, a property or a descriptor, retrieve the documentation string from the inheritance hierarchy. Return null if the documentation string is invalid or missing.
getfile(Object? object) → String?
Return the name of the (text or binary) file in which an object was defined. This will fail with a TypeError if the object is a built-in module, class, or function.
getFunction(String name) → PythonFunctionInterface<PythonFfiDelegate<Object?>, Object?>
Gets the function with the given name.
inherited
getmembers(Object? object, [bool predicate(Object? value)?]) → Iterable<(String, Object?)>
Return all the members of an object in a list of (name, value) pairs sorted by name. If the optional predicate argument — which will be called with the value object of each member — is supplied, only members for which the predicate returns a true value are included.
getmembers_static(Object? object, [bool predicate(Object? value)?]) → Iterable<(String, Object?)>
Return all the members of an object in a list of (name, value) pairs sorted by name without triggering dynamic lookup via the descriptor protocol, getattr or getattribute. Optionally, only return members that satisfy a given predicate.
getmodule(Object? object) → PythonModuleInterface<PythonFfiDelegate<Object?>, Object?>?
Try to guess which module an object was defined in. Return null if the module cannot be determined.
getsource(Object? object) → String?
Return the text of the source code for an object. The argument may be a module, class, method, function, traceback, frame, or code object. The source code is returned as a single string. An OSError is raised if the source code cannot be retrieved. A TypeError is raised if the object is a built-in module, class, or function.
hasAttribute(String attributeName) → bool
Checks if the python object has the given attribute.
inherited
isbuiltin(Object? object) → bool
Return true if the object is a built-in function or a bound built-in method.
isclass(Object? object) → bool
Return true if the object is a class, whether built-in or created in Python code.
isfunction(Object? object) → bool
Return true if the object is a Python function, which includes functions created by a lambda expression.
ismethod(Object? object) → bool
Return true if the object is a bound method written in Python.
ismethodwrapper(Object? object) → bool
Return true if the type of object is a MethodWrapperType.
ismodule(Object? object) → bool
Return true if the object is a module.
noSuchMethod(Invocation invocation) → Object?
Invoked when a nonexistent method or property is accessed.
inherited
setAttribute<T extends Object?>(String attributeName, T value) → void
Sets the attribute with the given name.
inherited
setAttributeRaw<T extends PythonObjectInterface<PythonFfiDelegate<Object?>, Object?>>(String attributeName, T value) → void
Sets the attribute with the given name.
inherited
signature(PythonFunctionInterface<PythonFfiDelegate<Object?>, Object?> callable, {bool follow_wrapped = true, Object? globals, Object? locals, bool eval_str = false}) → Signature
Return a Signature object for the given callable :
toDartObject() → Object?
Converts the python object to a Dart object.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

import() → inspect
Primary constructor for this module.
override