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

◆ Merge() [1/2]

void System.Xml.Serialization.XmlSchemas.Merge ( IList originals,
XmlSchema schema )
inlineprivate

Definition at line 429 of file XmlSchemas.cs.

430 {
431 foreach (XmlSchema original in originals)
432 {
433 if (schema == original)
434 {
435 return;
436 }
437 }
438 foreach (XmlSchemaExternal include in schema.Includes)
439 {
441 {
443 if (include.Schema != null)
444 {
445 Merge(include.Schema);
446 }
447 else
448 {
450 }
451 }
452 else if (include.Schema == null)
453 {
454 if (include.SchemaLocation != null)
455 {
457 }
458 }
459 else
460 {
462 Merge(originals, include.Schema);
463 }
464 }
465 bool[] array = new bool[schema.Items.Count];
466 int num = 0;
467 for (int i = 0; i < schema.Items.Count; i++)
468 {
471 if (xmlSchemaObject2 != null)
472 {
473 if (!Cache.Match(xmlSchemaObject2, xmlSchemaObject, _shareTypes))
474 {
476 }
477 array[i] = true;
478 num++;
479 }
480 }
481 if (num == schema.Items.Count)
482 {
483 return;
484 }
486 for (int j = 0; j < schema.Items.Count; j++)
487 {
488 if (!array[j])
489 {
490 xmlSchema2.Items.Add(schema.Items[j]);
491 }
492 }
495 }
void Add(TKey key, TValue value)
static string Format(string resourceFormat, object p1)
Definition SR.cs:118
static string XmlSchemaIncludeLocation
Definition SR.cs:1748
Definition SR.cs:7
static void Preprocess(XmlSchema schema)
static string MergeFailedMessage(XmlSchemaObject src, XmlSchemaObject dest, string ns)
void AddImport(IList schemas, string ns)
void Merge(XmlSchema schema)
object? Find(XmlQualifiedName name, Type type)

References System.Xml.Serialization.XmlSchemas._shareTypes, System.Collections.Generic.Dictionary< TKey, TValue >.Add(), System.Xml.Serialization.XmlSchemas.AddImport(), System.array, System.Collections.Generic.Dictionary< TKey, TValue >.Count, System.Xml.Dictionary, System.Xml.Serialization.XmlSchemas.Find(), System.SR.Format(), System.Xml.Serialization.XmlSchemas.Merge(), System.Xml.Serialization.XmlSchemas.MergeFailedMessage(), System.Xml.Name, System.Xml.Schema.Namespace, System.Xml.Serialization.XmlSchemas.Preprocess(), System.Xml.Serialization.XmlSchemas.XmlSchema, and System.SR.XmlSchemaIncludeLocation.