[squeak-dev] ImageSegment vs SmartRefStream

Mariano Martinez Peck marianopeck at gmail.com
Tue Dec 22 14:19:33 UTC 2009


On Tue, Dec 22, 2009 at 2:17 PM, Lukas Renggli <renggli at gmail.com> wrote:

> > 1) which is the difference between ImageSegment and SmartRefStream ? what
> > does each of them do ?
>
> ImageSegment depends on SmartRefStream. SmartRefStream is independent
> of ImageSegment and can also be used alone.
>
>
ok...


> > 2) Who uses who ? ImageSegment uses SmartRefStream or vice-versa?  each
> one
> > use the other?
>
> ImageSegment uses SmartRefStream to serialize itself.


ok, can I ask where in the code is that?   Maybe when ImageSegment uses the
method fileOutClass: nil andObject:   (in ImageSegment >>
writeForExportOn:)  ?

But this is only used when you want to export an ImageSegment to another
image. If you want to swap out an ImageSegment and then load it again, I
think it doesn't use SmartRefStream because it just write to file the
wordarray. (ImageSegment >> writeToFile)

I am correct ?

That includes
> its internal state (the image segment object), the ByteArray that the
> VM primitive produces, as well as incoming and outgoing references
> (for example classes and symbols).
>
> > 3) Which is the difference between ReferenceStream and SmartRefStream ?
>
> SmartRefStream can handle class shape changes. ReferenceStream not.
>
>
Ok, thanks :)


> Lukas
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20091222/a693a66d/attachment.htm


More information about the Squeak-dev mailing list