Exemple #1
0
 internal void ToXml(AutoCSer.XmlSerializer serializer)
 {
     if (MemberMap == null || MemberMap.IsDefault)
     {
         serializer.TypeSerialize(Value);
     }
     else
     {
         AutoCSer.Metadata.MemberMap memberMap = serializer.SetCustomMemberMap(MemberMap);
         try
         {
             serializer.TypeSerialize(Value);
         }
         finally { serializer.SetCustomMemberMap(memberMap); }
     }
 }
Exemple #2
0
 internal void Serialize(AutoCSer.XmlSerializer serializer)
 {
     serializer.TypeSerialize(Value == null ? 1 : 2);
 }