aiida.sphinxext package

Defines reStructuredText directives to simplify documenting AiiDA and its plugins.

aiida.sphinxext.setup(app)[source]

Setup function to add the extension classes / nodes to Sphinx.

Submodules

Defines an rst directive to auto-document AiiDA calculation job.

class aiida.sphinxext.calcjob.AiidaCalcJobDirective(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)[source]

Bases: aiida.sphinxext.process.AiidaProcessDirective

__module__ = 'aiida.sphinxext.calcjob'
annotation = 'calcjob'
signature = 'CalcJob'
class aiida.sphinxext.calcjob.AiidaCalcJobDocumenter(*args)[source]

Bases: aiida.sphinxext.process.AiidaProcessDocumenter

Sphinx Documenter for AiiDA CalcJobs.

__module__ = 'aiida.sphinxext.calcjob'
classmethod can_document_member(member, membername, isattr, parent)[source]

Called to see if a member can be documented by this documenter.

directivetype = 'aiida-calcjob'
objtype = 'calcjob'
priority = 20
aiida.sphinxext.calcjob.setup_extension(app)[source]

Defines an rst directive to auto-document AiiDA processes.

class aiida.sphinxext.process.AiidaProcessDirective(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)[source]

Bases: docutils.parsers.rst.Directive

Directive to auto-document AiiDA processes.

EXPAND_NAMESPACES_FLAG = 'expand-namespaces'
HIDE_UNSTORED_INPUTS_FLAG = 'hide-nondb-inputs'
__module__ = 'aiida.sphinxext.process'
annotation = 'process'
build_content()[source]

Returns the main content (docstring, inputs, outputs) of the documentation.

build_doctree(title, port_namespace)[source]

Returns a doctree for a given port namespace, including a title.

build_node_tree()[source]

Returns the docutils node tree.

build_outline_doctree(outline)[source]

Build the doctree for a spec outline.

build_outline_lines(outline, indent)[source]

Return a list of lines which describe the process outline.

build_port_content(name, port)[source]

Build the content that describes a single port.

build_portnamespace_doctree(port_namespace)[source]

Builds the doctree for a port namespace.

build_signature()[source]

Returns the signature of the process.

final_argument_whitespace = True
static format_valid_types(valid_type)[source]

Format valid types.

has_content = True
initialize()[source]

Set internal attributes of the class.

Includes importing the process class.

option_spec = {'expand-namespaces': <function flag>, 'hide-nondb-inputs': <function flag>, 'module': <function unchanged>}
optional_arguments = 0
required_arguments = 1
run()[source]
signature = 'Process'
class aiida.sphinxext.process.AiidaProcessDocumenter(*args)[source]

Bases: sphinx.ext.autodoc.ClassDocumenter

Sphinx Documenter class for AiiDA Processes.

__module__ = 'aiida.sphinxext.process'
classmethod can_document_member(member, membername, isattr, parent)[source]

Called to see if a member can be documented by this documenter.

directivetype = 'aiida-process'
objtype = 'process'
priority = 10
aiida.sphinxext.process._is_non_db(port)[source]
aiida.sphinxext.process.setup_extension(app)[source]

Defines an rst directive to auto-document AiiDA workchains.

class aiida.sphinxext.workchain.AiidaWorkChainDocumenter(*args)[source]

Bases: aiida.sphinxext.process.AiidaProcessDocumenter

Sphinx Documenter class for AiiDA WorkChains.

__module__ = 'aiida.sphinxext.workchain'
classmethod can_document_member(member, membername, isattr, parent)[source]

Called to see if a member can be documented by this documenter.

directivetype = 'aiida-workchain'
objtype = 'workchain'
priority = 20
class aiida.sphinxext.workchain.AiidaWorkchainDirective(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)[source]

Bases: aiida.sphinxext.process.AiidaProcessDirective

__module__ = 'aiida.sphinxext.workchain'
annotation = 'workchain'
signature = 'WorkChain'
aiida.sphinxext.workchain.setup_extension(app)[source]