Meta¶
Meta Models¶
license: | MIT, see LICENSE for more details |
---|---|
copyright: | 2020 Aquiles Carattino |
-
class
experimentor.models.meta.
MetaModel
(name, bases, attrs)[source]¶ Meta Model type which will be responsible for keeping track of all the created models in the program. This is very useful for things like automatically building a GUI, initializing/finishing all the devices, etc. and also to perform checks at the beginning of the runtime, by doing introspection on all the defined models, regardless of whether they are instantiated later on or no.
One of the tasks is to generate a list of signals available in each model. Signals are specified as class attributes and therefore they can be accounted for before instantiating the class. Once the class is being instantiated, each object will re-instantiate the signals in order to keep its own copy, and establishing the proper owner of the signal.