class ApiObject: (source)
Known subclasses: docspec.Function
, docspec.HasMembers
, docspec.Indirection
, docspec.Variable
The base class for representing "API Objects". Any API object is any addressable entity in code, be that a variable/constant, function, class or module.
Method | __post |
Undocumented |
Method | parent |
Undocumented |
Method | sync |
Synchronize the hierarchy of this API object and all of it's children. This should be called when the #HasMembers.members are updated to ensure that all child objects reference the right #parent. Loaders are expected to return #ApiObject#s in a fully synchronized state such that the user does not have to call this method unless they are doing modifications to the tree. |
Class Variable | docstring |
Undocumented |
Class Variable | location |
Undocumented |
Class Variable | name |
Undocumented |
Instance Variable | parent |
Returns the parent of the #HasMembers. Note that if you make any modifications to the API object tree, you will need to call #sync_hierarchy() afterwards because adding to #Class.members or #Module.members does not automatically keep the #parent property in sync. |
Property | path |
Returns a list of all of this API object's parents, from top to bottom. The list includes *self* as the last item. |
Instance Variable | _parent |
Undocumented |
docspec.HasMembers
Synchronize the hierarchy of this API object and all of it's children. This should be called when the #HasMembers.members are updated to ensure that all child objects reference the right #parent. Loaders are expected to return #ApiObject#s in a fully synchronized state such that the user does not have to call this method unless they are doing modifications to the tree.
Parameters | |
parent:t.Optional[ | Undocumented |
docspec.HasMembers
Returns the parent of the #HasMembers. Note that if you make any modifications to the API object tree, you will need to call #sync_hierarchy() afterwards because adding to #Class.members or #Module.members does not automatically keep the #parent property in sync.