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

◆ OnXmlReservedAttribute()

void System.Xml.XmlTextReaderImpl.OnXmlReservedAttribute ( NodeData attr)
inlineprivate

Definition at line 4844 of file XmlTextReaderImpl.cs.

4845 {
4846 string localName = attr.localName;
4847 if (!(localName == "space"))
4848 {
4849 if (localName == "lang")
4850 {
4852 {
4854 }
4855 _xmlContext.xmlLang = attr.StringValue;
4856 }
4857 return;
4858 }
4860 {
4862 }
4863 string text = XmlConvert.TrimString(attr.StringValue);
4864 if (!(text == "preserve"))
4865 {
4866 if (text == "default")
4867 {
4868 _xmlContext.xmlSpace = XmlSpace.Default;
4869 }
4870 else
4871 {
4872 Throw(System.SR.Xml_InvalidXmlSpace, attr.StringValue, attr.lineInfo.lineNo, attr.lineInfo.linePos);
4873 }
4874 }
4875 else
4876 {
4877 _xmlContext.xmlSpace = XmlSpace.Preserve;
4878 }
4879 }
static string Xml_InvalidXmlSpace
Definition SR.cs:92
Definition SR.cs:7
void Throw(int pos, string res, string arg)

References System.Xml.XmlTextReaderImpl._curNode, System.Xml.Dictionary, System.Xml.XmlTextReaderImpl.PushXmlContext(), System.text, System.Xml.XmlTextReaderImpl.Throw(), System.Xml.XmlConvert.TrimString(), System.SR.Xml_InvalidXmlSpace, and System.Xml.XmlTextReaderImpl.NodeData.xmlContextPushed.

Referenced by System.Xml.XmlTextReaderImpl.AddDefaultAttributeInternal(), System.Xml.XmlTextReaderImpl.ParseAttributes(), and System.Xml.XmlTextReaderImpl.ParseAttributesAsync().