mbdlyb_ui.functional.hardware
Copyright (c) 2023 - 2026 TNO-ESI All rights reserved.
Classes
Display the affects relation create editing page. |
|
Display the affects relation update editing page. |
|
Represent an editable hardware fault. |
|
Display the hardware create editing page. |
|
Display the hardware details properties and relations. |
|
Display the hardware update editing page. |
|
Display the observes relation create editing page. |
|
Display the observes relation update editing page. |
|
Display the realizes relation create editing page. |
|
Display the realizes relation update editing page. |
|
Display the tests relation create editing page. |
|
Display the tests relation update editing page. |
Functions
|
Append a hardware fault and refresh the fault table. |
|
Render the affected node and relation weight controls. |
|
Remove a hardware fault and refresh the fault table. |
|
Render editable hardware fault rows. |
|
Render the hardware name, states, and fault controls. |
|
Render the observed node and relation weight controls. |
|
Render the realized function and relation weight controls. |
|
Render the tested node and relation weight controls. |
Module Contents
- class mbdlyb_ui.functional.hardware.AffectsRelationCreatePage(hardware_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the affects relation create editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.AffectsRelationUpdatePage(hardware_id: str, function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the affects relation update editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.Fault(name: str, prior: float)
Represent an editable hardware fault.
- classmethod from_list(l: list[Fault])
Convert editable fault entries to stored prior probabilities.
- Parameters:
l – Editable cost or fault entries to convert into a stored mapping.
- Returns:
Mapping of entry names to their configured numeric values.
- classmethod to_list(d: dict[str, float]) list[Fault]
Convert stored fault rates to editable fault entries.
- Parameters:
d – Stored name-to-value pairs to convert into editable entries.
- Returns:
Editable entries created from the stored name-to-value mapping.
- name
- prior
- class mbdlyb_ui.functional.hardware.HardwareCreatePage(cluster_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the hardware create editing page.
- fault_rates
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.HardwareDetailsPage(hardware_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the hardware details properties and relations.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.HardwareUpdatePage(hardware_id)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the hardware update editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.ObservesRelationCreatePage(hardware_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the observes relation create editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.ObservesRelationUpdatePage(hardware_id: str, observable_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the observes relation update editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.RealizesRelationCreatePage(hardware_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the realizes relation create editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.RealizesRelationUpdatePage(hardware_id: str, function_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the realizes relation update editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.TestsRelationCreatePage(hardware_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the tests relation create editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- class mbdlyb_ui.functional.hardware.TestsRelationUpdatePage(hardware_id: str, test_id: str)
Bases:
mbdlyb_ui.functional.base.FunctionalPageDisplay the tests relation update editing page.
- hardware: mbdlyb.functional.gdb.GHardware
- mbdlyb_ui.functional.hardware.add_fault(fault_rates: list[Fault])
Append a hardware fault and refresh the fault table.
- Parameters:
fault_rates – Editable hardware faults and their rates.
- mbdlyb_ui.functional.hardware.affects_relation_form(relation: mbdlyb_ui.functional.helpers.AffectsRelation, root: mbdlyb.functional.gdb.GCluster)
Render the affected node and relation weight controls.
- Parameters:
relation – Relation whose endpoints and weight are edited.
root – Root cluster used to list eligible relation targets.
- mbdlyb_ui.functional.hardware.drop_fault(fault_rates: list[Fault], fault: Fault)
Remove a hardware fault and refresh the fault table.
- Parameters:
fault_rates – Editable hardware faults and their rates.
fault – Fault or cost entry selected for removal.
- mbdlyb_ui.functional.hardware.fault_table(fault_rates: list[Fault])
Render editable hardware fault rows.
- Parameters:
fault_rates – Editable hardware faults and their rates.
- mbdlyb_ui.functional.hardware.hardware_form(hardware: mbdlyb.functional.gdb.GHardware, fault_rates: list[Fault], cluster: mbdlyb.functional.gdb.GCluster, update: bool = True)
Render the hardware name, states, and fault controls.
- Parameters:
hardware – Hardware node whose properties are edited.
fault_rates – Editable hardware faults and their rates.
cluster – Parent cluster used to validate the hardware name.
update – Whether the hardware already exists for name validation.
- mbdlyb_ui.functional.hardware.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.hardware.realizes_relation_form(relation: mbdlyb_ui.functional.helpers.RealizesRelation)
Render the realized function and relation weight controls.
- Parameters:
relation – Relation whose endpoints and weight are edited.
- mbdlyb_ui.functional.hardware.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.