Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Cleanup() [2/2]

static void System.Xml.Schema.SchemaCollectionCompiler.Cleanup ( XmlSchema schema)
inlinestaticpackage

Definition at line 85 of file SchemaCollectionCompiler.cs.

86 {
87 for (int i = 0; i < schema.Includes.Count; i++)
88 {
89 XmlSchemaExternal xmlSchemaExternal = (XmlSchemaExternal)schema.Includes[i];
90 if (xmlSchemaExternal.Schema != null)
91 {
93 }
94 if (!(xmlSchemaExternal is XmlSchemaRedefine xmlSchemaRedefine))
95 {
96 continue;
97 }
98 xmlSchemaRedefine.AttributeGroups.Clear();
99 xmlSchemaRedefine.Groups.Clear();
100 xmlSchemaRedefine.SchemaTypes.Clear();
101 for (int j = 0; j < xmlSchemaRedefine.Items.Count; j++)
102 {
103 object obj = xmlSchemaRedefine.Items[j];
104 if (obj is XmlSchemaAttribute attribute)
105 {
107 }
108 else if (obj is XmlSchemaAttributeGroup attributeGroup)
109 {
111 }
112 else if (obj is XmlSchemaComplexType complexType)
113 {
115 }
116 else if (obj is XmlSchemaSimpleType simpleType)
117 {
119 }
120 else if (obj is XmlSchemaElement element)
121 {
122 CleanupElement(element);
123 }
124 else if (obj is XmlSchemaGroup group)
125 {
127 }
128 }
129 }
130 for (int k = 0; k < schema.Items.Count; k++)
131 {
132 object obj2 = schema.Items[k];
133 if (obj2 is XmlSchemaAttribute attribute2)
134 {
136 }
137 else if (schema.Items[k] is XmlSchemaAttributeGroup attributeGroup2)
138 {
140 }
141 else if (schema.Items[k] is XmlSchemaComplexType complexType2)
142 {
144 }
145 else if (schema.Items[k] is XmlSchemaSimpleType simpleType2)
146 {
148 }
149 else if (schema.Items[k] is XmlSchemaElement element2)
150 {
152 }
153 else if (schema.Items[k] is XmlSchemaGroup group2)
154 {
156 }
157 }
158 schema.Attributes.Clear();
159 schema.AttributeGroups.Clear();
160 schema.SchemaTypes.Clear();
161 schema.Elements.Clear();
162 schema.Groups.Clear();
163 schema.Notations.Clear();
164 schema.Ids.Clear();
165 schema.IdentityConstraints.Clear();
166 }
static void CleanupAttribute(XmlSchemaAttribute attribute)
static void CleanupComplexType(XmlSchemaComplexType complexType)
static void CleanupElement(XmlSchemaElement element)
static void CleanupSimpleType(XmlSchemaSimpleType simpleType)
static void CleanupAttributeGroup(XmlSchemaAttributeGroup attributeGroup)

References System.Xml.Schema.SchemaCollectionCompiler.Cleanup(), System.Xml.Schema.SchemaCollectionCompiler.CleanupAttribute(), System.Xml.Schema.SchemaCollectionCompiler.CleanupAttributeGroup(), System.Xml.Schema.SchemaCollectionCompiler.CleanupComplexType(), System.Xml.Schema.SchemaCollectionCompiler.CleanupElement(), System.Xml.Schema.SchemaCollectionCompiler.CleanupGroup(), System.Xml.Schema.SchemaCollectionCompiler.CleanupSimpleType(), System.Collections.Generic.Dictionary< TKey, TValue >.Clear(), System.Collections.Generic.Dictionary< TKey, TValue >.Count, System.Xml.Dictionary, and System.obj.