Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Developing U++ » U++ Developers corner » Xmlize values
Re: Xmlize values [message #25504 is a reply to message #25503] Fri, 26 February 2010 13:12 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13976
Registered: November 2005
Ultimate Member
mdelfede wrote on Fri, 26 February 2010 06:37

luzr wrote on Fri, 26 February 2010 11:57

I was thinking about Xmlize Value problem and I think this should be quite a fine solution:

First, Xmlize itself should know all Values that are in the Core (I guess we are there already, right?).

Then, add registering mechanism for unknown Values. Anyway, I think it would be better not to register any values automatically, because that would link all XML code into any application. So

Last but not least, for non-registered Values, use binary serialization and put a hex string there. Important - this should be signalled in the serialization so that even if type is registered later, old XML files can still be loaded.

What do you think?

Mirek


That would be the best, besides (maybe) some problems that can arise in binary serialization of unknown types, if types are non-POD ones (don't know if Value can store such types).



Oh, I have meant only types that have binary serialization support in Value, of course...

Quote:


About the non-auto registering of all value types.... fine, but if you forget to register it you'll have it binary serialized, not very nice.



True, but XML being backward compatible gives you oportunity to fix that later...

Quote:


Maybe a conditional code part that does the registering only if XML code is included would be fine.



Maybe. Perhaps needs more thinking...
Ciao

Max
[/quote]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Strange Win7 issue with large fonts...
Next Topic: libpng1.4
Goto Forum:
  


Current Time: Thu May 09 16:09:47 CEST 2024

Total time taken to generate the page: 0.01505 seconds