polygene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stanislav Muhametsin <stanislav.muhamet...@kapsi.fi>
Subject Re: Massive Refactoring in ZEST-105 branch
Date Thu, 17 Dec 2015 13:32:28 GMT
On 17.12.2015 15:25, Niclas Hedhman wrote:
> Sooooo.... I have tried to straighten up the difference between the "Model"
> and the "Instances", especially for the ModuleInstance, which was heavily
> overloaded with Model stuff.
> The interesting bit about the Modules (and Application and Layer too) is
> that there is one model and one instance, so it is possible to go from one
> to the other and back. Does that sound right?

Strictly my personal opinion, but no, it doesn't sound right.
IMO instance should know its model, but models should not know instances 
that are created off the model.

In Qi4CS I have three layers: assembly, model, instance.
Assemblies are quite close to the ones in Zest - they are the ones that 
are manipulated by users of Qi4CS/Zest.
Models are created from assembly - these are immutable, and they 
restructure all the type information in assembly into more coherent data 
structures.
And, as stated above, instances are created from models.

I've made this layer separation so explicit that even namespaces in 
Qi4CS are something like this:
Qi4CS.API.Assembling
Qi4CS.API.Model
Qi4CS.API.Instance
Qi4CS.SPI.Assembling
etc...



Mime
View raw message