-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: Document the derived context feature
- Loading branch information
Showing
5 changed files
with
65 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<!-- | ||
~ SPDX-FileCopyrightText: 2022 Copyright DB InfraGO AG and the capellambse-context-diagrams contributors | ||
~ SPDX-License-Identifier: Apache-2.0 | ||
--> | ||
|
||
# Derived diagram elements | ||
|
||
With capellambse-context-diagrams | ||
[`v0.2.36`](https://github.com/DSD-DBS/capellambse-context-diagrams/releases/tag/v0.2.36) | ||
a separate context is built. The elements are derived from the diagram target, | ||
i.e. the system of interest on which `context_diagram` was called on. The | ||
render parameter to enable this feature is called `display_derived_interfaces` | ||
and is available on: | ||
|
||
- `LogicalComponent`s and | ||
- `SystemComponent`s | ||
|
||
!!! example "Context Diagram with derived elements" | ||
|
||
```py | ||
from capellambse import MelodyModel | ||
|
||
lost = model.by_uuid("0d18f31b-9a13-4c54-9e63-a13dbf619a69") | ||
diag = obj.context_diagram | ||
diag.render( | ||
"svgdiagram", display_derived_interfaces=True | ||
).save(pretty=True) | ||
``` | ||
<figure markdown> | ||
<img src="../../assets/images/Context of Center-derived.svg" width="1000000"> | ||
<figcaption>Context diagram of <b>Center</b> with derived context</figcaption> | ||
</figure> | ||
|
||
See [`the derivator | ||
functions`][capellambse_context_diagrams.collectors.default.DERIVATORS] to gain | ||
an overview over all supported capellambse types and the logic to derive | ||
elements. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters