mbdlyb_ui.functional.functions
Copyright (c) 2023 - 2026 TNO-ESI All rights reserved.
Classes
Represent an editable form required for relation. |
|
Display the function CPT probability table editor. |
|
Display the function create editing page. |
|
Display the function detail properties and relations. |
|
Display the function update editing page. |
|
Display the observes relation create editing page. |
|
Display the observes relation update editing page. |
|
Display the required for relation create editing page. |
|
Display the required for relation repair editing page. |
|
Display the required for relation update editing page. |
|
Display the subfunction relation create editing page. |
|
Display the subfunction relation table relation table. |
|
Display the subfunction relation update editing page. |
|
Display the tests relation create editing page. |
|
Display the tests relation update editing page. |
Functions
|
Append a required-for repair relation and refresh the table. |
|
Remove a required-for repair relation and refresh the table. |
|
Render the function name and state editing controls. |
|
Render the observed node and relation weight controls. |
|
Render editable required-for repair relation rows. |
|
Render the required-for target, weight, and operating mode controls. |
|
Render editable repair relations and associated costs. |
|
Render the parent function and relation weight controls. |
|
Render the tested node and relation weight controls. |
Module Contents
- class mbdlyb_ui.functional.functions.FormRequiredForRelation(idx: int, start_node: mbdlyb.functional.gdb.GFunction, end_node: mbdlyb.functional.gdb.GFunction | None = None, weight: float | None = None, operating_modes: list[str] | None = None)
Bases:
mbdlyb_ui.functional.helpers.RequiredForRelationRepresent an editable form required for relation.
- idx
- class mbdlyb_ui.functional.functions.FunctionCPTPage(function_id: str)
Bases:
mbdlyb_ui.functional.base.CPTPageDisplay the function CPT probability table editor.
- class mbdlyb_ui.functional.functions.FunctionCreatePage(cluster_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the function create editing page.
- function: mbdlyb.functional.gdb.GFunction
- class mbdlyb_ui.functional.functions.FunctionDetailPage(function_id)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the function detail properties and relations.
- function: mbdlyb.functional.gdb.GFunction
- class mbdlyb_ui.functional.functions.FunctionUpdatePage(function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the function update editing page.
- function: mbdlyb.functional.gdb.GFunction
- class mbdlyb_ui.functional.functions.ObservesRelationCreatePage(function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the observes relation create editing page.
- function: mbdlyb.functional.gdb.GFunction
- o_relation: mbdlyb_ui.functional.helpers.ObservesRelation
- class mbdlyb_ui.functional.functions.ObservesRelationUpdatePage(function_id: str, observable_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the observes relation update editing page.
- function: mbdlyb.functional.gdb.GFunction
- o_relation: mbdlyb_ui.functional.helpers.ObservesRelation
- class mbdlyb_ui.functional.functions.RequiredForRelationCreatePage(function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the required for relation create editing page.
- function: mbdlyb.functional.gdb.GFunction
- rf_relation: mbdlyb_ui.functional.helpers.RequiredForRelation
- class mbdlyb_ui.functional.functions.RequiredForRelationRepairPage(function_id: str, dep_function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the required for relation repair editing page.
- function: mbdlyb.functional.gdb.GFunction
- rf_relation: FormRequiredForRelation
- rf_relations: list[FormRequiredForRelation]
- class mbdlyb_ui.functional.functions.RequiredForRelationUpdatePage(function_id: str, dep_function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the required for relation update editing page.
- function: mbdlyb.functional.gdb.GFunction
- rf_relation: mbdlyb_ui.functional.helpers.RequiredForRelation
- class mbdlyb_ui.functional.functions.SubfunctionRelationCreatePage(function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the subfunction relation create editing page.
- sf_relation: mbdlyb_ui.functional.helpers.SubfunctionOfRelation
- class mbdlyb_ui.functional.functions.SubfunctionRelationTablePage(function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the subfunction relation table relation table.
- eligable_sfs: dict[str, dict]
- function: mbdlyb.functional.gdb.GFunction
- groups: dict[str, list[str]]
- class mbdlyb_ui.functional.functions.SubfunctionRelationUpdatePage(function_id: str, subfunction_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the subfunction relation update editing page.
- sf_relation: mbdlyb_ui.functional.helpers.SubfunctionOfRelation
- class mbdlyb_ui.functional.functions.TestsRelationCreatePage(function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the tests relation create editing page.
- function: mbdlyb.functional.gdb.GFunction
- t_relation: mbdlyb_ui.functional.helpers.TestsRelation
- class mbdlyb_ui.functional.functions.TestsRelationUpdatePage(function_id: str, test_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the tests relation update editing page.
- function: mbdlyb.functional.gdb.GFunction
- t_relation: mbdlyb_ui.functional.helpers.TestsRelation
- mbdlyb_ui.functional.functions.add_rfr(rf_relations: list[FormRequiredForRelation], initial: FormRequiredForRelation)
Append a required-for repair relation and refresh the table.
- Parameters:
rf_relations – Editable required-for repair relations.
initial – Whether to create the first repair relation.
- mbdlyb_ui.functional.functions.drop_rfr(rf_relations: list[FormRequiredForRelation], rf_relation: FormRequiredForRelation)
Remove a required-for repair relation and refresh the table.
- Parameters:
rf_relations – Editable required-for repair relations.
rf_relation – Required-for relation being edited.
- mbdlyb_ui.functional.functions.function_form(function: mbdlyb.functional.gdb.GFunction, states: mbdlyb_ui.functional.helpers.StateTable, cluster: mbdlyb.functional.gdb.GCluster, update: bool = True)
Render the function name and state editing controls.
- Parameters:
function – Function whose properties are edited.
states – Editable state names for the function.
cluster – Parent cluster used to validate the function name.
update – Whether the function already exists for name validation.
- mbdlyb_ui.functional.functions.observes_relation_form(o_relation: mbdlyb_ui.functional.helpers.ObservesRelation)
Render the observed node and relation weight controls.
- Parameters:
o_relation – Observes relation being edited.
- mbdlyb_ui.functional.functions.repair_rfr_table(rf_relations: list[FormRequiredForRelation], initial_relation: FormRequiredForRelation, start_options: dict[str, str] | None = None, end_options: dict[str, str] | None = None)
Render editable required-for repair relation rows.
- Parameters:
rf_relations – Editable required-for repair relations.
initial_relation – Original required-for relation used for repair.
start_options – Available source nodes for the relation.
end_options – Available target nodes for the relation.
- mbdlyb_ui.functional.functions.requiredfor_relation_form(rf_relation: mbdlyb_ui.functional.helpers.RequiredForRelation, root: mbdlyb.functional.gdb.GCluster)
Render the required-for target, weight, and operating mode controls.
- Parameters:
rf_relation – Required-for relation being edited.
root – Root cluster used to list eligible relation targets.
- mbdlyb_ui.functional.functions.requiredfor_relation_repair_form(rf_relations: list[FormRequiredForRelation], initial_relation: FormRequiredForRelation)
Render editable repair relations and associated costs.
- Parameters:
rf_relations – Editable required-for repair relations.
initial_relation – Original required-for relation used for repair.
- mbdlyb_ui.functional.functions.subfunction_relation_form(sf_relation: mbdlyb_ui.functional.helpers.SubfunctionOfRelation)
Render the parent function and relation weight controls.
- Parameters:
sf_relation – Subfunction relation being edited.
- mbdlyb_ui.functional.functions.tests_relation_form(t_relation: mbdlyb_ui.functional.helpers.TestsRelation)
Render the tested node and relation weight controls.
- Parameters:
t_relation – Tests relation being edited.