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

◆ Compile()

void System.Xml.Serialization.XmlSchemas.Compile ( ValidationEventHandler? handler,
bool fullCompile )
inline

Definition at line 665 of file XmlSchemas.cs.

666 {
667 if (_isCompiled)
668 {
669 return;
670 }
672 {
673 Merge(value);
674 }
676 if (fullCompile)
677 {
678 _schemaSet = new XmlSchemaSet();
681 foreach (XmlSchema value2 in References.Values)
682 {
684 }
685 int num = _schemaSet.Count;
686 foreach (XmlSchema item in base.List)
687 {
688 if (!SchemaSet.Contains(item))
689 {
691 num++;
692 }
693 }
694 if (!SchemaSet.Contains("http://www.w3.org/2001/XMLSchema"))
695 {
698 num++;
699 }
700 if (!SchemaSet.Contains("http://www.w3.org/XML/1998/namespace"))
701 {
704 num++;
705 }
709 return;
710 }
711 try
712 {
713 XmlNameTable nameTable = new System.Xml.NameTable();
718 foreach (XmlSchema item2 in SchemaSet.Schemas())
719 {
720 preprocessor.Execute(item2, item2.TargetNamespace, loadExternals: true);
721 }
722 }
723 catch (XmlSchemaException ex)
724 {
725 throw CreateValidationException(ex, ex.Message);
726 }
727 }
virtual ICollection Values
Definition Hashtable.cs:534
bool Contains(string? targetNamespace)
XmlSchema? Add(string? targetNamespace, string schemaUri)
void AddReference(XmlSchema schema)
void Merge(XmlSchema schema)
static Exception CreateValidationException(XmlSchemaException exception, string message)

References System.Xml.Serialization.XmlSchemas._isCompiled, System.Xml.Serialization.XmlSchemas._schemaSet, System.Xml.Schema.XmlSchemaSet.Add(), System.Xml.Serialization.XmlSchemas.AddReference(), System.Collections.Hashtable.Clear(), System.Xml.Schema.XmlSchemaSet.Compile(), System.Xml.Schema.XmlSchemaSet.Contains(), System.Xml.Schema.XmlSchemaSet.Count, System.Xml.Serialization.XmlSchemas.CreateValidationException(), System.Xml.Serialization.XmlSchemas.delayedSchemas, System.Xml.Dictionary, System.item, System.Xml.Serialization.XmlSchemas.Merge(), System.Xml.Serialization.XmlSchemas.References, System.Xml.Schema.XmlSchemaSet.Schemas(), System.Xml.Serialization.XmlSchemas.SchemaSet, System.value, System.Collections.Hashtable.Values, and System.Xml.Serialization.XmlSchemas.XsdSchema.

Referenced by System.Xml.Serialization.SchemaGraph.SchemaGraph().