
May 13th, 2003, 05:44 PM
|
|
Junior Member
|
|
Join Date: May 2003
Posts: 1
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
Hmmm ...
... found XmlSerializer pretty cool at the 1st look as well, BUT:
The hard part comes when the classes you want to serialize are composed from complex types, and even worse, if these are coming from referenced libraries.
XmlSerializer construction exceptions (like IO/exception cannot load library 1bj3fh.dll, mumble, mumble) are hard to debug :-(.
In my environment I'm using complex object graphs, that cross reference subsystems of the entire (3-tier) application system.
Unfortunately I noticed as well, that XmlSerializer provides no
useful overriding of control of XML-serialization and formatting when inheriting your own serializer class.
Actually I'm considering using wrapper classes, specially designed for serialization of my complex objects (of course those can be serialized using XmlSerializer then). The wrapper could drill down the object graph to primitive types and sequences.
As well I have the problem to distinguish referenced from embedded objects. When working in memory they behave the same way, as object instances. But when serializing them, I don't want to follow the object graphs of referenced objects, they can be identified with a unique (persistent) ID.
Another choice would be DataTransferObject/Assembler pair, but writing (serializable) DTOs is so stupid, may be xsd.exe is helpful with this task.
Just my 2˘,
Günther
|