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

◆ PreprocessElement()

void System.Xml.Schema.SchemaCollectionPreprocessor.PreprocessElement ( XmlSchemaElement element)
inlineprivate

Definition at line 865 of file SchemaCollectionPreprocessor.cs.

866 {
867 if (element.Name != null)
868 {
869 ValidateNameAttribute(element);
870 element.SetQualifiedName(new XmlQualifiedName(element.Name, _targetNamespace));
871 }
872 else
873 {
875 }
877 if (element.Final == XmlSchemaDerivationMethod.All)
878 {
879 element.SetFinalResolved(XmlSchemaDerivationMethod.All);
880 }
881 else if (element.Final == XmlSchemaDerivationMethod.None)
882 {
883 if (_finalDefault == XmlSchemaDerivationMethod.All)
884 {
885 element.SetFinalResolved(XmlSchemaDerivationMethod.All);
886 }
887 else
888 {
889 element.SetFinalResolved(_finalDefault & (XmlSchemaDerivationMethod.Extension | XmlSchemaDerivationMethod.Restriction));
890 }
891 }
892 else
893 {
894 if (((uint)element.Final & 0xFFFFFFF9u) != 0)
895 {
897 }
898 element.SetFinalResolved(element.Final & (XmlSchemaDerivationMethod.Extension | XmlSchemaDerivationMethod.Restriction));
899 }
900 if (element.Form != 0)
901 {
903 }
904 if (element.MinOccursString != null)
905 {
907 }
908 if (element.MaxOccursString != null)
909 {
911 }
912 if (!element.SubstitutionGroup.IsEmpty)
913 {
914 ValidateQNameAttribute(element, "type", element.SubstitutionGroup);
915 }
916 ValidateIdAttribute(element);
917 }
static string Sch_ForbiddenAttribute
Definition SR.cs:544
static string Sch_InvalidElementFinalValue
Definition SR.cs:512
static string Sch_MissRequiredAttribute
Definition SR.cs:490
Definition SR.cs:7
void SendValidationEvent(string code, XmlSchemaObject source)
void ValidateQNameAttribute(XmlSchemaObject xso, string attributeName, XmlQualifiedName value)

References System.Xml.Schema.SchemaCollectionPreprocessor._finalDefault, System.Xml.Schema.SchemaCollectionPreprocessor._targetNamespace, System.Xml.Schema.XmlSchemaElement.Final, System.Xml.Schema.XmlSchemaElement.Form, System.Xml.XmlQualifiedName.IsEmpty, System.Xml.Schema.XmlSchemaParticle.MaxOccursString, System.Xml.Schema.XmlSchemaParticle.MinOccursString, System.Xml.Schema.XmlSchemaElement.Name, System.Xml.Schema.SchemaCollectionPreprocessor.PreprocessElementContent(), System.SR.Sch_ForbiddenAttribute, System.SR.Sch_InvalidElementFinalValue, System.SR.Sch_MissRequiredAttribute, System.Xml.Schema.BaseProcessor.SendValidationEvent(), System.Xml.Schema.XmlSchemaElement.SetFinalResolved(), System.Xml.Schema.XmlSchemaElement.SetQualifiedName(), System.Xml.Schema.XmlSchemaElement.SubstitutionGroup, System.Xml.Schema.SchemaCollectionPreprocessor.ValidateIdAttribute(), System.Xml.Schema.SchemaCollectionPreprocessor.ValidateNameAttribute(), and System.Xml.Schema.SchemaCollectionPreprocessor.ValidateQNameAttribute().

Referenced by System.Xml.Schema.SchemaCollectionPreprocessor.Preprocess().