std.serialization

Orvid King blah38621 at gmail.com
Sun Feb 16 14:21:44 PST 2014


> I already have all this in Orange [1], which I'm in progress of adapting  
> to a package for Phobos.
>
...
>
> This requires registering the subclass in some way. In my implementation  
> one needs to call:
>
> Serializer.register!(Sub);
>
> For full example see [2].
>
> [1] https://github.com/jacob-carlborg/orange
> [2] https://github.com/jacob-carlborg/orange/wiki/Base-Class
>

The problem with the way your doing it though is that it requires that the  
library doing the deserialization is fully aware of the semantics used in  
the serialization implementation, rather than just the syntax and  
semantics of the selected serialization format.


More information about the Digitalmars-d-announce mailing list