class documentation

class ApiObject:

Known subclasses: docspec.Data, docspec.Function, docspec.HasMembers, docspec.Indirection

View In Hierarchy

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​_init__ Undocumented
Method parent.setter Undocumented
Method sync​_hierarchy No summary
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
def __post_init__(self):

Undocumented

@parent.setter
def parent(self, parent):

Undocumented

Parameters
parent:t.Optional[HasMembers]Undocumented
def sync_hierarchy(self, parent=None):
overridden in 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[HasMembers]Undocumented
docstring: t.Optional[Docstring] =

Undocumented

location: t.Optional[Location] =

Undocumented

name: str =

Undocumented

@property
parent =
overridden in 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.
@property
path: t.List[ApiObject] =
Returns a list of all of this API object's parents, from top to bottom. The list includes self as the last item.
_parent =

Undocumented