Skip to content

Commit

Permalink
merge: Add Scenario realization links (#480)
Browse files Browse the repository at this point in the history
  • Loading branch information
Wuestengecko committed Dec 10, 2024
2 parents 863137f + 2965ebb commit 2e65e49
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions capellambse/metamodel/interaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,14 @@ class Scenario(m.ModelElement):
time_lapses = m.Containment("ownedTimeLapses", aslist=m.MixedElementList)
postcondition = m.Association(capellacore.Constraint, "postCondition")
precondition = m.Association(capellacore.Constraint, "preCondition")
realized_scenarios = m.Allocation["Scenario"](
"ownedScenarioRealization",
"org.polarsys.capella.core.data.interaction:ScenarioRealization",
attr="targetElement",
backattr="sourceElement",
aslist=m.ElementList,
)
realizing_scenarios: m.Backref[Scenario]

@property
def related_functions(self) -> m.ElementList[fa.AbstractFunction]:
Expand Down Expand Up @@ -200,4 +208,9 @@ class AbstractFunctionAbstractCapabilityInvolvement(AbstractInvolvement):
"""An abstract CapabilityInvolvement linking to SystemFunctions."""


Scenario.realizing_scenarios = m.Backref(
Scenario, "realized_scenarios", aslist=m.ElementList
)


from . import fa

0 comments on commit 2e65e49

Please sign in to comment.