xbrl.taxonomy.RelationshipNetwork

An xbrl.taxonomy.RelationshipNetwork class represents the network of relationships for a base set in the DTS.

class xbrl.taxonomy.RelationshipNetwork

Proper instances of this class will be created within RaptorXML only, instantiation from script code will throw a NotImplementedError exception.

Attributes

xbrl.taxonomy.RelationshipNetwork.relationships

Returns an iterator of xbrl.taxonomy.Relationship objects which represent the relationships in this base set.

xbrl.taxonomy.RelationshipNetwork.root_nodes

Returns an iterator of xbrl.taxonomy.RelationshipNetworkNode objects which represent the root nodes in the network of relationships. Root nodes are defined as all nodes in the network of relationships that do not appear on the target side of any relationship.

xbrl.taxonomy.RelationshipNetwork.roots

Returns an iterator of objects which represent the root elements in the network of relationships spanned by this base set.

Methods

xbrl.taxonomy.RelationshipNetwork.node(obj)

Returns a xbrl.taxonomy.RelationshipNetworkNode object which represents the node for the argument obj in the network of relationships. Argument obj can be an XML element, XLink resource, XBRL concept or fact. The depth of the returned node is initialized to zero.

xbrl.taxonomy.RelationshipNetwork.relationships_from(obj)

Returns an iterator of xbrl.taxonomy.Relationship objects which represent the relationships in this base set that originate from the XML element represented by the given object.

xbrl.taxonomy.RelationshipNetwork.relationships_to(obj)

Returns an iterator of xbrl.taxonomy.Relationship objects which represent the relationships in this base set that lead to the XML element represented by the given object.

xbrl.taxonomy.RelationshipNetwork.walk(source=None, *, axis=xbrl_formula.AxisType.DESCENDANT, generations=None)

Returns an iterator of xbrl.taxonomy.RelationshipNetworkNode objects which represent the nodes on the given axis starting from source. Argument source can be an XML element, XLink resource, XBRL concept or fact. If generations is specified with a value greater than zero, the iterator will stop after the specified number of transitions.

Special methods

__bool__, __eq__, __ge__, __gt__, __le__, __lt__, __ne__