Persisting 'applications'

Cowdery, Bob [UK] Bob.Cowdery at CGI-Europe.com
Thu Feb 23 09:49:51 UTC 2006



Chris

Thank you very much, I'm on the straight and narrow now. The ability to
build multiple configurations and just persist them is magic. 


> sdrBackplane := myMagmaSession root at:
> 'SDRBackplane'
> 
> to get a reference and then
> 
> myMagmaSession root: sdrBackplane
> MagmaSession cleanup
> myMagmaSession root removeKey: 'SDRBackplane'

>> There's no need to reset the root again, it was
>> already there since you just got it in the first line.

Sorry, bad copy and paste.

>> The cleanUp is just an old sort of 'advanced utility'
>> method for dereferencing objects from temps in
>> MethodContexts..  It has nothing to do with removing
>> anything from a database, just from image memory; I'm
>> actually not sure whether its needed anymore since I
>>discovered #fixTemps..

That explains why it cleaned out objects in my image that I couldn't
seem to get rid of.

>> I line 3 is wrapped in a commit, as in:

>>  myMagmaSession commit: [ myMagmaSession root
>> removeKey: 'SDRBackplane' ]

Of course, having a bit of a blond day.


>> Ah, ok.  So maybe the connectors should maintain their
>> state in the World at runtime..  Hard to know.

For the moment I'm happy I can work round that.

> So if you tell me how to delete objects reliably
> from Magma I think I might
> be there.

>> Dereferencing any sub-part of your object-model is a
>> matter of changing the reference to point to the nil
>> object (wrapped in commit, of course).

Everything cleaned so now I can start building.

 - Bob
*** Confidentiality Notice *** Proprietary/Confidential
Information belonging to CGI Group Inc. and its affiliates
may be contained in this message. If you are not a recipient
indicated or intended in this message (or responsible for
delivery of this message to such person), or you think for
any reason that this message may have been addressed to you
in error, you may not use or copy or deliver this message
to anyone else.  In such case, you should destroy this
message and are asked to notify the sender by reply email.



More information about the Squeak-dev mailing list