PAK Core – IModelCollector
The model collector interface defines all necessary methods, which might be called to fetch models from remote repositories. It is used to resolve and collect models during the runtime of the engine.
1. Signature
This section further outlines the signature of the interface before describing where the framework will access the methods.
|
Loads the meta information for a model with the given name, group and version |
|
Loads the metas for all models the collector is able to find |
|
Downloads the real model associated to a given meta. Returns a |
2. Sub-Model Handling
The model collector interface plays a major role in the execution of sub-models. It will be used during any Dataflow Analysis as well as during the initialization of the engine.
2.1. Dataflow Analysis
When enabled in the engine config, a Dataflow Analysis will be run before the root-model is executed. The analyser will look for sub-models recursively by using loadModel(name, group, version)
. Should any sub-model not include a version, loadModels()
will be called once in order to resolve models manually. The analyser will assure that all mappings will be present before engine execution.
2.2. Engine Initialization
After an engine start was requested, the engine will look recursively for all sub-models registered to the root model. This is done by using the same methods as described above. Should any model not be found during the initialization, the engine will fail to execute the root model. All sub-models will be created and initialized beforehand in order to reduce the time needed for the engine run itself.