Newer
Older
from traits.api import ABCHasStrictTraits, Instance, List
from force_bdss.core.kpi_specification import KPISpecification
from .parameters.base_mco_parameter import BaseMCOParameter
from .i_mco_factory import IMCOFactory
"""Base class for the specific MCO models.
This model will also provide, through traits/traitsui magic the View
that will appear in the workflow manager UI.
In your definition, your specific model must reimplement this class.
#: A reference to the creating factory, so that we can
factory = Instance(IMCOFactory,
visible=False,
transient=True)
parameters = List(BaseMCOParameter, visible=False)
kpis = List(KPISpecification, visible=False)
def __init__(self, factory, *args, **kwargs):
self.factory = factory
super(BaseMCOModel, self).__init__(*args, **kwargs)