Skip to content
Snippets Groups Projects
Commit 96bb5b25 authored by Frederik Hennig's avatar Frederik Hennig
Browse files

commenced work on documentation

parent ca3ebac4
Branches
Tags
No related merge requests found
Pipeline #57236 failed with stage
in 15 seconds
## Modules
To Do
\ No newline at end of file
# Source File Composition
::: pystencilssfg.composer.SfgComposer
::: pystencilssfg.source_components.SfgKernelNamespace
::: pystencilssfg.source_components.SfgKernelHandle
h2.doc-heading {
font-size: x-large
}
h3.doc-heading {
font-size: large;
}
.doc-class>.doc-heading::before {
font-size: small;
content: "class ";
margin-right: 5pt;
}
.doc-contents {
border-left: 3pt solid rgb(60, 60, 60);
padding-left: 10pt;
}
.doc-class .doc-children .doc-attribute>.doc-heading::before {
font-size: small;
content: "attribute ";
margin-right: 5pt;
}
.doc-class .doc-children .doc-function>.doc-heading::before {
font-size: small;
content: "function ";
margin-right: 5pt;
}
.doc-children {
padding-left: 10pt;
}
\ No newline at end of file
site_name: pystencils Source File Generator Documentation
theme:
name: material
features: navigation.tabs
palette:
scheme: slate
primary: deep purple
extra_css:
- css/mkdocstrings.css
plugins:
- search
- autorefs
- mkdocstrings:
default_handler: python
handlers:
python:
paths: [src]
options:
heading_level: 2
show_root_heading: True
show_root_full_path: False
show_symbol_type_heading: True
show_symbol_type_toc: True
show_source: False
show_signature_annotations: True
signature_crossrefs: True
nav:
- Home: index.md
- API Documentation: api.md
- 'API Documentation':
- 'Overview': api/index.md
- 'Source File Generator Front-End': api/frontend.md
- 'Kernel Call Tree': api/tree.md
\ No newline at end of file
......@@ -16,14 +16,18 @@ if TYPE_CHECKING:
class SfgComposer:
"""Primary interface for constructing source files in pystencils-sfg."""
def __init__(self, ctx: SfgContext):
self._ctx = ctx
@property
def kernels(self) -> SfgKernelNamespace:
"""The default kernel namespace."""
return self._ctx._default_kernel_namespace
def kernel_namespace(self, name: str) -> SfgKernelNamespace:
"""Returns the kernel namespace of the given name, creating it if it does not exist yet."""
kns = self._ctx.get_kernel_namespace(name)
if kns is None:
kns = SfgKernelNamespace(self, name)
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment