unknown_serializable_properties


Description:

public abstract Map<string,Attribute> unknown_serializable_properties { owned get; }

On deserialization stores any GXml.Attribute not used on this object, but exists in current XML file.

Node's name is used as key to find stored GXml.Attribute, key is case sensitive.

XML allows great flexibility, providing different ways to represent the same information. This is a problem when you try to deserialize them.

In order to deserialize correctly, you must create your XML, both by serializing a Serializable object or by hand writing. By using the former, you can add extra information, like attributes, but most of them could be ignored or lost on deserialization/serialization process. To avoid data lost, you can override get_enable_unknown_serializable_property method in order to return true, your implementation or the ones in GXml, will store all unknown attributes on deserialization and must serialize again back to the XML file. Even you are allowed to get this unknown objects by iterating on unknown_serializable_properties collection, if you know attribute's name, use it to retrieve it.

This property is ignored on serialisation.