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

◆ WriteXmlnsAttribute() [3/4]

virtual void System.Xml.XmlDictionaryWriter.WriteXmlnsAttribute ( string? prefix,
string namespaceUri )
inlinevirtualinherited

Definition at line 345 of file XmlDictionaryWriter.cs.

346 {
347 if (namespaceUri == null)
348 {
350 }
351 if (prefix == null)
352 {
353 if (LookupPrefix(namespaceUri) != null)
354 {
355 return;
356 }
357 prefix = ((namespaceUri.Length == 0) ? string.Empty : $"d{namespaceUri.Length}");
358 }
359 WriteAttributeString("xmlns", prefix, null, namespaceUri);
360 }
void WriteAttributeString(XmlDictionaryString localName, XmlDictionaryString? namespaceUri, string? value)
string? LookupPrefix(string ns)

References System.Xml.Dictionary, System.Xml.XmlWriter.LookupPrefix(), System.prefix, System.Runtime.Serialization.DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull(), and System.Xml.XmlDictionaryWriter.WriteAttributeString().

Referenced by System.Runtime.Serialization.XmlWriterDelegator.WriteXmlnsAttribute(), System.Xml.XmlDictionaryAsyncCheckWriter.WriteXmlnsAttribute(), System.Xml.XmlDictionaryAsyncCheckWriter.WriteXmlnsAttribute(), System.Runtime.Serialization.XmlWriterDelegator.WriteXmlnsAttribute(), System.Xml.XmlDictionaryWriter.WriteXmlnsAttribute(), and System.Runtime.Serialization.XmlWriterDelegator.WriteXmlnsAttribute().