polenter / SharpSerializer

SharpSerializer can serialize types like: multidimensional array, nested array, array-of-arrays, polymorphic object (where value is inherited from the property type), generic type, generic listing (i.e. dictionary, collection) and many more, with a single line of code
https://www.sharpserializer.net
Other
114 stars 28 forks source link

DateTimeKind is deserialized as Unspecified, using binary serialization. #20

Closed polenter closed 2 years ago

polenter commented 2 years ago

DateTime with a defined Kind is not binary deserialized (Kind equals Unspecified). The XML serialization works as expected.

Since additional information must be stored, the fix would result with breaking change in the serialization stream. I suggest replacing DateTime against DateTimeOffset.

Originally posted by @AntiTenzor in https://github.com/polenter/SharpSerializer/issues/17#issuecomment-994484009