:py:mod:`raesl.excel` ===================== .. py:module:: raesl.excel .. autoapi-nested-parse:: Module to export as an Excel workbook. Submodules ---------- .. toctree:: :titlesonly: :maxdepth: 1 cli/index.rst defaults/index.rst sheets/index.rst text/index.rst utils/index.rst Package Contents ---------------- Functions ~~~~~~~~~ .. autoapisummary:: raesl.excel.register_locale raesl.excel.get_scoped_nodes raesl.excel.convert raesl.excel.overview raesl.excel.component_overview Attributes ~~~~~~~~~~ .. autoapisummary:: raesl.excel.logger .. py:data:: logger .. py:function:: register_locale(locale: str = 'en') Register a locale. Existing locales are re-registered. .. py:function:: get_scoped_nodes(graph: ragraph.graph.Graph, scopes: Dict[str, Optional[int]]) -> List[ragraph.node.Node] Get scoped nodes, being subtrees of the graph of varying depth. :param graph: Graph data. :param scopes: Node names mapped to depths of the subtree to include. A depth of :obj:`None` includes the whole subtree starting at that node. :returns: List of nodes in all given scopes. .. py:function:: convert(*paths: Union[str, pathlib.Path], output: Optional[Union[str, pathlib.Path]] = defaults.OUTPUT, scopes: Dict[str, Optional[int]] = defaults.SCOPES, language: str = 'en') -> openpyxl.workbook.Workbook Write (part of) an ESL specification to a Excel workbook. :param paths: ESL specification paths. :param output: Optional Workbook output path (will be overwritten without warning). :param scopes: Dictionary of component paths to relative depths of subcomponents to include as scopes for the generated output. Defaults to the complete tree. :returns: Excel workbook instance. .. py:function:: overview(graph: ragraph.graph.Graph, output: Optional[Union[str, pathlib.Path]] = defaults.OUTPUT, scopes: Dict[str, Optional[int]] = defaults.SCOPES, language: str = 'en') -> openpyxl.workbook.Workbook Write (part of) an ESL specification to a Excel workbook. :param graph: Compiled ESL graph. :param output: Optional Workbook output path (will be overwritten without warning). :param scopes: Dictionary of component paths to relative depths of subcomponents to include as scopes for the generated output. Defaults to the complete tree. :returns: Excel workbook instance. .. py:function:: component_overview(graph: ragraph.graph.Graph, component_path: str, flow_labels: Optional[List[str]] = None, output: Optional[Union[str, pathlib.Path]] = None, language: str = 'en') -> openpyxl.workbook.Workbook Create a component overview Excel sheet. Somewhat like a free body diagram for a single component. Meant to be more discrete but also compact than the complete overview Excel. :param paths: ESL specification paths. :param flow_types: Flow types to include in sheets. :param output: Optional Workbook output path (will be overwritten without warning). :returns: Excel workbook instance.