Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
XmlObjectSerializerReadContext.cs
Go to the documentation of this file.
3using System.Text;
4using System.Xml;
6
8
10{
12
14
16
18
20
22
24
26 {
27 get
28 {
29 if (_deserializedObjects == null)
30 {
32 }
34 }
35 }
36
38
39 internal override bool IsGetOnlyCollection
40 {
41 get
42 {
44 }
45 set
46 {
48 }
49 }
50
51 internal object GetCollectionMember()
52 {
54 }
55
61
63 {
66 }
67
73
79
88
93
99
100 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
106
107 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
113
114 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
116 {
117 if (dataContract == null)
118 {
120 }
122 }
123
124 protected bool TryHandleNullOrRef(XmlReaderDelegator reader, Type declaredType, string name, string ns, ref object retObj)
125 {
126 ReadAttributes(reader);
128 {
130 {
132 }
134 reader.Skip();
135 return true;
136 }
137 if (attributes.XsiNil)
138 {
139 reader.Skip();
140 return true;
141 }
142 return false;
143 }
144
145 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
146 protected object InternalDeserialize(XmlReaderDelegator reader, string name, string ns, Type declaredType, ref DataContract dataContract)
147 {
148 object retObj = null;
149 if (TryHandleNullOrRef(reader, dataContract.UnderlyingType, name, ns, ref retObj))
150 {
151 return retObj;
152 }
153 bool flag = false;
154 if (dataContract.KnownDataContracts != null)
155 {
156 scopedKnownTypes.Push(dataContract.KnownDataContracts);
157 flag = true;
158 }
159 if (attributes.XsiTypeName != null)
160 {
162 if (dataContract2 == null)
163 {
164 if (base.DataContractResolver == null)
165 {
167 }
169 }
171 flag = ReplaceScopedKnownTypesTop(dataContract.KnownDataContracts, flag);
172 }
173 if (dataContract.IsISerializable && attributes.FactoryTypeName != null)
174 {
176 if (dataContract3 != null)
177 {
178 if (!dataContract3.IsISerializable)
179 {
181 }
183 flag = ReplaceScopedKnownTypesTop(dataContract.KnownDataContracts, flag);
184 }
185 }
186 if (flag)
187 {
188 object result = ReadDataContractValue(dataContract, reader);
190 return result;
191 }
192 return ReadDataContractValue(dataContract, reader);
193 }
194
196 {
198 {
201 }
202 if (knownDataContracts != null)
203 {
204 scopedKnownTypes.Push(knownDataContracts);
206 }
208 }
209
211 {
212 return xmlReader.MoveToContent() != XmlNodeType.EndElement;
213 }
214
215 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
217 {
218 for (int i = memberIndex + 1; i < memberNames.Length; i++)
219 {
220 if (xmlReader.IsStartElement(memberNames[i], memberNamespaces[i]))
221 {
222 return i;
223 }
224 }
226 return memberNames.Length;
227 }
228
229 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
246
265
266 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
268 {
269 xmlReader.MoveToContent();
270 if (xmlReader.NodeType != XmlNodeType.Element)
271 {
273 }
274 if (base.IgnoreExtensionDataObject || extensionData == null)
275 {
277 }
278 else
279 {
281 }
282 }
283
284 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
293
299
300 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
317
318 [MemberNotNull("attributes")]
320 {
321 if (attributes == null)
322 {
323 attributes = new Attributes();
324 }
326 }
327
328 internal void ResetAttributes()
329 {
330 if (attributes != null)
331 {
333 }
334 }
335
336 internal string GetObjectId()
337 {
338 return attributes.Id;
339 }
340
341 internal virtual int GetArraySize()
342 {
343 return -1;
344 }
345
346 internal void AddNewObject(object obj)
347 {
349 }
350
351 internal void AddNewObjectWithId(string id, object obj)
352 {
353 if (id != Globals.NewObjectId)
354 {
356 }
357 }
358
373
374 internal object GetExistingObject(string id, Type type, string name, string ns)
375 {
376 object @object = DeserializedObjects.GetObject(id);
377 if (@object == null)
378 {
380 }
381 return @object;
382 }
383
384 private object GetExistingObjectOrExtensionData(string id)
385 {
386 object @object = DeserializedObjects.GetObject(id);
387 if (@object == null)
388 {
390 }
391 return @object;
392 }
393
404
412
413 internal static void ParseQualifiedName(string qname, XmlReaderDelegator xmlReader, out string name, out string ns, out string prefix)
414 {
415 int num = qname.IndexOf(':');
416 prefix = "";
417 if (num >= 0)
418 {
419 prefix = qname.Substring(0, num);
420 }
421 name = qname.Substring(num + 1);
422 ns = xmlReader.LookupNamespace(prefix);
423 }
424
425 internal static T[] EnsureArraySize<T>(T[] array, int index)
426 {
427 if (array.Length <= index)
428 {
429 if (index == int.MaxValue)
430 {
432 }
433 int num = ((index < 1073741823) ? (index * 2) : int.MaxValue);
434 T[] array2 = new T[num];
435 Array.Copy(array, array2, array.Length);
436 array = array2;
437 }
438 return array;
439 }
440
441 internal static T[] TrimArraySize<T>(T[] array, int size)
442 {
443 if (size != array.Length)
444 {
445 T[] array2 = new T[size];
446 Array.Copy(array, array2, size);
447 array = array2;
448 }
449 return array;
450 }
451
472
473 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
482
483 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
488
489 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
491 {
492 object obj = null;
494 if (isMemberType && !xmlDataContract.HasRoot)
495 {
496 xmlReader.Read();
497 xmlReader.MoveToContent();
498 }
499 if (xmlDataContract.UnderlyingType == Globals.TypeOfXmlElement)
500 {
501 if (!xmlReader.IsStartElement())
502 {
504 }
507 }
508 else if (xmlDataContract.UnderlyingType == Globals.TypeOfXmlNodeArray)
509 {
511 }
512 else
513 {
514 IXmlSerializable xmlSerializable = xmlDataContract.CreateXmlSerializableDelegate();
517 }
518 xmlSerializableReader.EndRead();
519 return obj;
520 }
521
522 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
524 {
527 while ((xmlNodeType = xmlReader.MoveToContent()) != XmlNodeType.EndElement)
528 {
529 if (xmlNodeType != XmlNodeType.Element)
530 {
532 }
533 if (xmlReader.NamespaceURI.Length != 0)
534 {
536 continue;
537 }
538 string name = XmlConvert.DecodeName(xmlReader.LocalName);
541 object value;
543 {
544 xmlReader.Skip();
545 value = GetExistingObject(attributes.Ref, null, name, string.Empty);
546 }
547 else if (attributes.XsiNil)
548 {
549 xmlReader.Skip();
550 value = null;
551 }
552 else
553 {
555 }
556 serializationInfo.AddValue(name, value);
557 }
558 return serializationInfo;
559 }
560
561 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
563 {
564 if (attributes.XsiTypeName != null)
565 {
567 }
568 return null;
569 }
570
571 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
581
582 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
584 {
587 IDataNode dataNode = null;
589 {
590 xmlReader.Skip();
592 object obj;
594 {
596 obj = dataNode2;
597 }
598 else
599 {
601 }
602 dataNode = (IDataNode)obj;
604 }
605 else if (attributes.XsiNil)
606 {
607 xmlReader.Skip();
608 dataNode = null;
609 }
610 else
611 {
612 string dataContractName = null;
613 string dataContractNamespace = null;
614 if (attributes.XsiTypeName != null)
615 {
618 }
620 {
623 }
624 else if (attributes.FactoryTypeName != null)
625 {
628 }
630 {
633 }
634 else
635 {
637 if (dataContract == null)
638 {
640 }
642 {
644 }
645 else if (dataContract.IsISerializable)
646 {
649 }
651 {
653 {
655 xmlReader.MoveToContent();
657 xmlReader.ReadEndElement();
658 }
659 else
660 {
661 dataNode = new DataNode<object>(xmlReader.ReadElementContentAsAnyType(dataContract.UnderlyingType));
663 }
664 }
666 {
667 dataNode = new DataNode<object>(((EnumDataContract)dataContract).ReadEnumValue(xmlReader));
669 }
671 {
674 }
676 {
679 }
680 }
681 }
682 return dataNode;
683 }
684
686 {
687 }
688
689 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
721
723 {
724 Type valueType = xmlReader.ValueType;
726 {
727 IDataNode dataNode = new DataNode<object>(xmlReader.ReadContentAsString());
729 dataNode.IsFinalValue = false;
730 xmlReader.ReadEndElement();
731 return dataNode;
732 }
734 xmlReader.ReadEndElement();
735 return result;
736 }
737
747
754
755 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
777
778 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
780 {
785 while ((xmlNodeType = xmlReader.MoveToContent()) != XmlNodeType.EndElement)
786 {
787 if (xmlNodeType != XmlNodeType.Element)
788 {
790 }
791 if (collectionDataNode.ItemName == null)
792 {
795 }
796 if (xmlReader.IsStartElement(collectionDataNode.ItemName, collectionDataNode.ItemNamespace))
797 {
798 if (collectionDataNode.Items == null)
799 {
801 }
803 }
804 else
805 {
807 }
808 }
809 xmlReader.ReadEndElement();
810 if (arraySZSize != -1)
811 {
813 if (collectionDataNode.Items == null)
814 {
815 if (collectionDataNode.Size > 0)
816 {
818 }
819 }
820 else if (collectionDataNode.Size != collectionDataNode.Items.Count)
821 {
823 }
824 }
825 else if (collectionDataNode.Items != null)
826 {
828 }
829 else
830 {
832 }
833 return collectionDataNode;
834 }
835
836 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
866
868 {
872 if (xmlReader.NodeType == XmlNodeType.EndElement)
873 {
874 return xmlDataNode;
875 }
877 IList<XmlNode> list2 = null;
878 XmlNodeType xmlNodeType = xmlReader.MoveToContent();
879 if (xmlNodeType != XmlNodeType.Text)
880 {
881 while (xmlReader.MoveToNextAttribute())
882 {
883 string namespaceURI = xmlReader.NamespaceURI;
884 if (namespaceURI != "http://schemas.microsoft.com/2003/10/Serialization/" && namespaceURI != "http://www.w3.org/2001/XMLSchema-instance")
885 {
886 if (list == null)
887 {
888 list = new List<XmlAttribute>();
889 }
890 list.Add((XmlAttribute)Document.ReadNode(xmlReader.UnderlyingReader));
891 }
892 }
894 }
895 while ((xmlNodeType = xmlReader.MoveToContent()) != XmlNodeType.EndElement)
896 {
897 if (xmlReader.EOF)
898 {
900 }
901 if (list2 == null)
902 {
903 list2 = new List<XmlNode>();
904 }
905 list2.Add(Document.ReadNode(xmlReader.UnderlyingReader));
906 }
907 xmlReader.ReadEndElement();
910 return xmlDataNode;
911 }
912
913 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
915 {
916 bool flag = true;
917 bool flag2 = true;
918 bool flag3 = true;
919 string strA = null;
920 string text = null;
923 if (namespaces != null)
924 {
926 foreach (KeyValuePair<string, string> @namespace in namespaces)
927 {
928 list2.Add(AddNamespaceDeclaration(@namespace.Key, @namespace.Value));
929 }
930 }
931 XmlNodeType nodeType;
932 while ((nodeType = xmlReader.NodeType) != XmlNodeType.EndElement)
933 {
934 if (nodeType == XmlNodeType.Element)
935 {
936 string namespaceURI = xmlReader.NamespaceURI;
937 string localName = xmlReader.LocalName;
938 if (flag)
939 {
940 flag = namespaceURI.Length == 0;
941 }
942 if (flag2)
943 {
944 if (text == null)
945 {
946 text = localName;
948 }
949 else
950 {
951 flag2 = string.CompareOrdinal(text, localName) == 0 && string.CompareOrdinal(strA, namespaceURI) == 0;
952 }
953 }
954 }
955 else
956 {
957 if (xmlReader.EOF)
958 {
960 }
961 if (IsContentNode(xmlReader.NodeType))
962 {
963 flag3 = (flag = (flag2 = false));
964 }
965 }
966 if (_attributesInXmlData == null)
967 {
969 }
971 XmlNode xmlNode = Document.ReadNode(xmlReader.UnderlyingReader);
973 if (namespaces == null)
974 {
976 {
978 }
980 {
982 }
983 }
984 }
985 xmlReader.ReadEndElement();
986 if (text != null && flag2)
987 {
989 }
990 if (flag)
991 {
993 }
994 if (flag3)
995 {
997 }
1003 return xmlDataNode;
1004 }
1005
1006 private bool IsContentNode(XmlNodeType nodeType)
1007 {
1008 switch (nodeType)
1009 {
1010 case XmlNodeType.ProcessingInstruction:
1011 case XmlNodeType.Comment:
1012 case XmlNodeType.DocumentType:
1013 case XmlNodeType.Whitespace:
1014 case XmlNodeType.SignificantWhitespace:
1015 return false;
1016 default:
1017 return true;
1018 }
1019 }
1020
1029
1031 {
1032 localName = localName ?? "wrapper";
1033 ns = ns ?? string.Empty;
1034 XmlElement xmlElement = document.CreateElement(prefix, localName, ns);
1035 if (xmlAttributes != null)
1036 {
1037 for (int i = 0; i < xmlAttributes.Count; i++)
1038 {
1039 xmlElement.Attributes.Append(xmlAttributes[i]);
1040 }
1041 }
1042 if (xmlChildNodes != null)
1043 {
1044 for (int j = 0; j < xmlChildNodes.Count; j++)
1045 {
1046 xmlElement.AppendChild(xmlChildNodes[j]);
1047 }
1048 }
1049 return xmlElement;
1050 }
1051
1053 {
1054 XmlAttribute xmlAttribute = ((prefix == null || prefix.Length == 0) ? Document.CreateAttribute(null, "xmlns", "http://www.w3.org/2000/xmlns/") : Document.CreateAttribute("xmlns", prefix, "http://www.w3.org/2000/xmlns/"));
1055 xmlAttribute.Value = ns;
1056 return xmlAttribute;
1057 }
1058
1063
1064 internal static Exception CreateSerializationException(string message)
1065 {
1067 }
1068
1069 [RequiresUnreferencedCode("Data Contract Serialization and Deserialization might require types that cannot be statically analyzed. Make sure all of the required types are preserved.")]
1071 {
1072 return dataContract.ReadXmlValue(reader, this);
1073 }
1074
1079
1081 {
1082 return attributes.ArraySZSize != -1;
1083 }
1084
1086 {
1087 return false;
1088 }
1089}
static unsafe void Copy(Array sourceArray, Array destinationArray, int length)
Definition Array.cs:624
void Add(TKey key, TValue value)
void Read(XmlReaderDelegator reader)
Definition Attributes.cs:49
static string GetClrTypeFullName(Type type)
static readonly string NewObjectId
Definition Globals.cs:172
static object GetRealObject(IObjectReference obj, StreamingContext context)
DataContract ResolveDataContractFromKnownTypes(XmlQualifiedName typeName)
virtual void CheckIfTypeSerializable(Type memberType, bool isMemberTypeSerializable)
bool ReplaceScopedKnownTypesTop(Dictionary< XmlQualifiedName, DataContract > knownDataContracts, bool knownTypesAddedInCurrentScope)
void HandleUnknownElement(XmlReaderDelegator xmlReader, ExtensionDataObject extensionData, int memberIndex)
static void ThrowRequiredMemberMissingException(XmlReaderDelegator xmlReader, int memberIndex, int requiredIndex, XmlDictionaryString[] memberNames)
virtual object InternalDeserialize(XmlReaderDelegator xmlReader, Type declaredType, DataContract dataContract, string name, string ns)
ExtensionDataMember ReadExtensionDataMember(XmlReaderDelegator xmlReader, int memberIndex)
int GetMemberIndexWithRequiredMembers(XmlReaderDelegator xmlReader, XmlDictionaryString[] memberNames, XmlDictionaryString[] memberNamespaces, int memberIndex, int requiredIndex, ExtensionDataObject extensionData)
void CheckEndOfArray(XmlReaderDelegator xmlReader, int arraySize, XmlDictionaryString itemName, XmlDictionaryString itemNamespace)
virtual object ReadDataContractValue(DataContract dataContract, XmlReaderDelegator reader)
static void ParseQualifiedName(string qname, XmlReaderDelegator xmlReader, out string name, out string ns, out string prefix)
IDataNode ReadExtensionDataValue(XmlReaderDelegator xmlReader, string dataContractName, string dataContractNamespace)
static XmlNode CreateWrapperXmlElement(XmlDocument document, IList< XmlAttribute > xmlAttributes, IList< XmlNode > xmlChildNodes, string prefix, string localName, string ns)
bool TryHandleNullOrRef(XmlReaderDelegator reader, Type declaredType, string name, string ns, ref object retObj)
virtual IDataNode ReadPrimitiveExtensionDataValue(XmlReaderDelegator xmlReader, string dataContractName, string dataContractNamespace)
static Exception CreateUnexpectedStateException(XmlNodeType expectedState, XmlReaderDelegator xmlReader)
object ReadIXmlSerializable(XmlReaderDelegator xmlReader, XmlDataContract xmlDataContract, bool isMemberType)
ClassDataNode ReadUnknownClassData(XmlReaderDelegator xmlReader, string dataContractName, string dataContractNamespace)
XmlObjectSerializerReadContext(DataContractSerializer serializer, DataContract rootTypeDataContract, DataContractResolver dataContractResolver)
IDataNode ReadUnknownPrimitiveData(XmlReaderDelegator xmlReader, Type type, string dataContractName, string dataContractNamespace)
void ReplaceDeserializedObject(string id, object oldObj, object newObj)
object GetExistingObject(string id, Type type, string name, string ns)
string ReadIfNullOrRef(XmlReaderDelegator xmlReader, Type memberType, bool isMemberTypeSerializable)
virtual object InternalDeserialize(XmlReaderDelegator xmlReader, Type declaredType, string name, string ns)
IDataNode ReadAndResolveUnknownXmlData(XmlReaderDelegator xmlReader, IDictionary< string, string > namespaces, string dataContractName, string dataContractNamespace)
virtual object InternalDeserialize(XmlReaderDelegator xmlReader, int id, RuntimeTypeHandle declaredTypeHandle, string name, string ns)
XmlReaderDelegator CreateReaderOverChildNodes(IList< XmlAttribute > xmlAttributes, IList< XmlNode > xmlChildNodes)
void HandleMemberNotFound(XmlReaderDelegator xmlReader, ExtensionDataObject extensionData, int memberIndex)
static XmlObjectSerializerReadContext CreateContext(DataContractSerializer serializer, DataContract rootTypeDataContract, DataContractResolver dataContractResolver)
CollectionDataNode ReadUnknownCollectionData(XmlReaderDelegator xmlReader, string dataContractName, string dataContractNamespace)
void InitializeExtensionDataNode(IDataNode dataNode, string dataContractName, string dataContractNamespace)
SerializationInfo ReadSerializationInfo(XmlReaderDelegator xmlReader, Type type)
static object ReadRootIXmlSerializable(XmlReaderDelegator xmlReader, XmlDataContract xmlDataContract, bool isMemberType)
IDataNode ReadUnknownXmlData(XmlReaderDelegator xmlReader, string dataContractName, string dataContractNamespace)
static object ReadIXmlSerializable(XmlSerializableReader xmlSerializableReader, XmlReaderDelegator xmlReader, XmlDataContract xmlDataContract, bool isMemberType)
XmlObjectSerializerReadContext(XmlObjectSerializer serializer, int maxItemsInObjectGraph, StreamingContext streamingContext, bool ignoreExtensionDataObject)
ISerializableDataNode ReadUnknownISerializableData(XmlReaderDelegator xmlReader, string dataContractName, string dataContractNamespace)
virtual XmlReaderDelegator CreateReaderDelegatorForReader(XmlReader xmlReader)
object InternalDeserialize(XmlReaderDelegator reader, string name, string ns, Type declaredType, ref DataContract dataContract)
int GetMemberIndex(XmlReaderDelegator xmlReader, XmlDictionaryString[] memberNames, XmlDictionaryString[] memberNamespaces, int memberIndex, ExtensionDataObject extensionData)
static Exception CreateSerializationExceptionWithReaderDetails(string errorMessage, XmlReaderDelegator reader)
static string TryAddLineInfo(XmlReaderDelegator reader, string errorMessage)
static SerializationException CreateSerializationException(string errorMessage)
static string UnknownNullType
Definition SR.cs:714
static string UnexpectedElementExpectingElements
Definition SR.cs:290
static string UnexpectedEndOfFile
Definition SR.cs:292
static string ErrorDeserializing
Definition SR.cs:88
static string ExpectingState
Definition SR.cs:110
static string Format(string resourceFormat, object p1)
Definition SR.cs:118
static string FactoryTypeNotISerializable
Definition SR.cs:696
static string ArrayExceededSize
Definition SR.cs:14
static string MaxArrayLengthExceeded
Definition SR.cs:206
static string FactoryObjectContainsSelfReference
Definition SR.cs:634
static string DeserializedObjectWithIdNotFound
Definition SR.cs:70
static string DcTypeNotResolvedOnDeserialize
Definition SR.cs:68
static string ArrayExceededSizeAttribute
Definition SR.cs:16
static string XmlStartElementExpected
Definition SR.cs:316
static string NullValueReturnedForGetOnlyCollection
Definition SR.cs:222
static string ErrorTypeInfo
Definition SR.cs:96
static string ArraySizeAttributeIncorrect
Definition SR.cs:668
static string DcTypeNotFoundOnDeserialize
Definition SR.cs:64
Definition SR.cs:7
static Type GetTypeFromHandle(RuntimeTypeHandle handle)
static ? string DecodeName(string? name)
Definition XmlConvert.cs:55
virtual ? XmlNode ReadNode(XmlReader reader)
XmlAttribute CreateAttribute(string name)
void Push(Dictionary< XmlQualifiedName, DataContract > dataContractDictionary)