Is there a way to choose default values of attributes that are not in the xml file during deserialization? If the mAge attribute is not present in the xml file,
mAge
use [OnDeserializing()]
and you set your values BEFORE the deserialization. So there is no check necessary, which could go wrong - what if the mAge was serialized to be 0?