Valeri Fine (Faine) writes:
>
> You may provide a custom Registry::Streamer method for you class
> That defines how to stream you objects from your container into ROOT buffer and how to recreate
> your container back.
>
> You can use
> http://root.cern.ch/root/htmldoc/src/TCollection.cxx.html#TCollection:Streamer
>
> as example.
> Hope this helps.
It does somewhat. I was thinking something like this must be
necessary, but I am still confused about the following: In the
b.IsReading() block of TCollection's Streamer (which I will need to
mirror), one loops over the number of objects to input and there is
code like:
TObject* obj;
//...
loop {
b >> obj;
}
If I write a RegistryItemXxx<T>:RegistryItem:TObject object in the
``IsWriting'' block, how will ROOT know to give me this full object
back, when all I call is TObject's operator>>().
I know that rootcint will generate an operator>>(TBuffer&,Class*&) for
the Class it is run on. Is this somehow called durring ``b >> obj;''?
Maybe this magic (using A.C. Clark's definition) is something
fundamental (seperate from the complication of templates) about ROOT's
I/O that I don't understand.
Thanks,
-Brett.
This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:35 MET