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

◆ CheckSchemaRoot()

bool System.Xml.Schema.Parser.CheckSchemaRoot ( SchemaType rootType,
[NotNullWhen(false)] out string code )
inlineprivate

Definition at line 117 of file Parser.cs.

118 {
119 code = null;
120 if (_schemaType == SchemaType.None)
121 {
123 }
124 switch (rootType)
125 {
126 case SchemaType.XSD:
127 if (_schemaType != SchemaType.XSD)
128 {
130 return false;
131 }
132 break;
133 case SchemaType.XDR:
134 if (_schemaType == SchemaType.XSD)
135 {
137 return false;
138 }
139 if (_schemaType != SchemaType.XDR)
140 {
142 return false;
143 }
144 break;
145 case SchemaType.None:
146 case SchemaType.DTD:
148 if (_schemaType == SchemaType.XSD)
149 {
151 }
152 return false;
153 }
154 return true;
155 }
static string Sch_MixSchemaTypes
Definition SR.cs:1122
static string Sch_XSDSchemaOnly
Definition SR.cs:1124
static string Sch_XSDSchemaRootExpected
Definition SR.cs:422
static string Sch_SchemaRootExpected
Definition SR.cs:420
Definition SR.cs:7
SchemaType _schemaType
Definition Parser.cs:8

References System.Xml.Schema.Parser._schemaType, System.Xml.Dictionary, System.SR.Sch_MixSchemaTypes, System.SR.Sch_SchemaRootExpected, System.SR.Sch_XSDSchemaOnly, and System.SR.Sch_XSDSchemaRootExpected.

Referenced by System.Xml.Schema.Parser.StartParsing(), and System.Xml.Schema.Parser.StartParsingAsync().