On 05/08/2015 10:38, Norbert Hartl wrote:
Am 05.08.2015 um 09:15 schrieb Iwan Vosloo
<iwan(a)reahl.org>rg>:
Hi,
Can someone perhaps explain what is meant by descriptions being dynamic in Magritte 3? I
see some references to this change on the web, but do not fully understand it. From what I
understand Magritte 2 used to cache them somewhere, and this is not done anymore. I'd
like to know where this caching used to be done and what is now different as a result in
Magritte 3.
In Magritte 2 descriptions are on the class side. So they are the same for every
instance of that class. If I remember correctly the MAPragmaBuilder built and cached the
descriptions for a class. In Magritte 3 the descriptions moved to instance side. This
enables the powers of having descriptions individually for a single instance but it makes
caching a task that is not possible. A single description can be different over time when
an instance changes state etc.
Thanks, Norbert. I get that, but when you do, for example:
aComponent := anObject asComponent.
then aComponent holds onto the description created above (in
asComponent's implementation), as I understand it.
This means that as long as aComponent exists, it will always refer to
the same description.
Is that understanding correct?
Thanks
- Iwan
--
Reahl, the Python only web framework:
http://www.reahl.org