class documentation

class CitationDomain(Domain):

View In Hierarchy

Domain for citations.
Method check​_consistency Do consistency checks (experimental).
Method clear​_doc Remove traces of a document in the domain-specific inventories.
Method merge​_domaindata Merge in data regarding docnames from a different domaindata inventory (coming from a subprocess in parallel builds).
Method note​_citation Undocumented
Method note​_citation​_reference Undocumented
Method resolve​_any​_xref Resolve the pending_xref node with the given target.
Method resolve​_xref Resolve the pending_xref node with the given typ and target.
Class Variable dangling​_warnings Undocumented
Class Variable label Undocumented
Class Variable name Undocumented
Property citation​_refs Undocumented
Property citations Undocumented

Inherited from Domain:

Method add​_object​_type Add an object type.
Method directive Return a directive adapter class that always gives the registered directive its full name ('domain:name') as self.name.
Method get​_enumerable​_node​_type Get type of enumerable nodes (experimental).
Method get​_full​_qualified​_name Return full qualified name for given node.
Method get​_objects Return an iterable of "object descriptions".
Method get​_type​_name Return full name for given ObjType.
Method process​_doc Process a document after it is read by the environment.
Method process​_field​_xref Process a pending xref created in a doc field. For example, attach information about the current scope.
Method role Return a role adapter function that always gives the registered role its full name ('domain:name') as the first argument.
Method setup Set up domain object.
Class Variable data​_version Undocumented
Class Variable enumerable​_nodes Undocumented
Class Variable initial​_data Undocumented
Instance Variable data Undocumented
Instance Variable directives Undocumented
Instance Variable indices Undocumented
Instance Variable object​_types Undocumented
Instance Variable roles Undocumented
Method __init__ Undocumented
Instance Variable ​_directive​_cache Undocumented
Instance Variable ​_role2type Undocumented
Instance Variable ​_role​_cache Undocumented
Instance Variable ​_type2role Undocumented
Instance Variable env Undocumented
Instance Variable objtypes​_for​_role Undocumented
Instance Variable role​_for​_objtype Undocumented
def check_consistency(self):
Do consistency checks (experimental).
def clear_doc(self, docname):
Remove traces of a document in the domain-specific inventories.
Parameters
docname:strUndocumented
def merge_domaindata(self, docnames, otherdata):
Merge in data regarding docnames from a different domaindata inventory (coming from a subprocess in parallel builds).
Parameters
docnames:List[str]Undocumented
otherdata:DictUndocumented
def note_citation(self, node):

Undocumented

Parameters
node:nodes.citationUndocumented
def note_citation_reference(self, node):

Undocumented

Parameters
node:pending_xrefUndocumented
def resolve_any_xref(self, env, fromdocname, builder, target, node, contnode):

Resolve the pending_xref node with the given target.

The reference comes from an "any" or similar role, which means that we don't know the type. Otherwise, the arguments are the same as for resolve_xref.

The method must return a list (potentially empty) of tuples ('domain:role', newnode), where 'domain:role' is the name of a role that could have created the same reference, e.g. 'py:func'. newnode is what resolve_xref would return.

New in version 1.3.
Parameters
env:BuildEnvironmentUndocumented
fromdocname:strUndocumented
builder:BuilderUndocumented
target:strUndocumented
node:pending_xrefUndocumented
contnode:ElementUndocumented
Returns
List[Tuple[str, Element]]Undocumented
def resolve_xref(self, env, fromdocname, builder, typ, target, node, contnode):

Resolve the pending_xref node with the given typ and target.

This method should return a new node, to replace the xref node, containing the contnode which is the markup content of the cross-reference.

If no resolution can be found, None can be returned; the xref node will then given to the :event:`missing-reference` event, and if that yields no resolution, replaced by contnode.

The method can also raise sphinx.environment.NoUri to suppress the :event:`missing-reference` event being emitted.

Parameters
env:BuildEnvironmentUndocumented
fromdocname:strUndocumented
builder:BuilderUndocumented
typ:strUndocumented
target:strUndocumented
node:pending_xrefUndocumented
contnode:ElementUndocumented
Returns
Optional[Element]Undocumented
dangling_warnings: dict[str, str] =
label: str =

Undocumented

name: str =

Undocumented

@property
citation_refs: Dict[str, Set[str]] =

Undocumented

@property
citations: Dict[str, Tuple[str, str, int]] =

Undocumented