Custom deserializatoin

jrvbdeveloper

Member
Joined
Jul 15, 2007
Messages
17
Programming Experience
Beginner
Hi,

I have a question on custom deserialization.

Lets say I have ObjA of ClassA which I will need to reconstruct upon deserialization. This class contains static information which the user will not be able to change once the object has been created based on a parameter the user selects.

My question is, would it be better to serialize and deserialize ObjA which has many fields, or would it be better to serialize the selected parameter and then recreate ObjA upon deserialization? The end result will be the same, but which is more effective?

Thanks in advance.
 
Just an opinion but if it were me I would go for the just serialize ObjA. Provided, that is, that ClassA has a constructor that takes an ObjA as a parameter. Otherwise serialize the whole thing.

My 2 cents. :)
 
Back
Top