Qt Should I derive from QDataStream?

Posted by ShaChris23 on Stack Overflow See other posts from Stack Overflow or by ShaChris23
Published on 2010-03-11T20:25:19Z Indexed on 2010/03/11 20:29 UTC
Read the original article Hit count: 91

Filed under:
|
|

I'm currently using QDataStream to serialize my classes. I have quite a few number of my own classes that I serialize often. Should I derive QDataStream to create my own DataStream class? Or is there a better pattern than this? Note that these custom classes are used by many of our projects, so maybe doing so will make coding easier.

Another way to phrase this question is: when a framework provides you with a serialization class, how do you handle serializing your own custom-type classes such that you don't have to remember how to serialize them everytime.

© Stack Overflow or respective owner

Related posts about qt

Related posts about c++