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

◆ WriteQualifiedNameAsync() [1/2]

override async Task System.Xml.XmlWellFormedWriter.WriteQualifiedNameAsync ( string localName,
string ns )
inline

Definition at line 4115 of file XmlWellFormedWriter.cs.

4116 {
4117 _ = 4;
4118 try
4119 {
4120 if (localName == null || localName.Length == 0)
4121 {
4123 }
4124 CheckNCName(localName);
4126 string text = string.Empty;
4127 if (ns != null && ns.Length != 0)
4128 {
4129 text = LookupPrefix(ns);
4130 if (text == null)
4131 {
4132 if (_currentState != State.Attribute)
4133 {
4135 }
4136 text = GeneratePrefix();
4138 }
4139 }
4140 if (SaveAttrValue || _rawWriter == null)
4141 {
4142 if (text.Length != 0)
4143 {
4146 }
4147 await WriteStringAsync(localName).ConfigureAwait(continueOnCapturedContext: false);
4148 }
4149 else
4150 {
4152 }
4153 }
4154 catch
4155 {
4156 _currentState = State.Error;
4157 throw;
4158 }
4159 }
static string Format(string resourceFormat, object p1)
Definition SR.cs:118
static string Xml_EmptyLocalName
Definition SR.cs:294
static string Xml_UndefNamespace
Definition SR.cs:290
Definition SR.cs:7
new ConfiguredTaskAwaitable< TResult > ConfigureAwait(bool continueOnCapturedContext)
Definition Task.cs:226
override Task WriteQualifiedNameAsync(string localName, string ns)
void PushNamespaceImplicit(string prefix, string ns)
override Task WriteStringAsync(string text)
override string LookupPrefix(string ns)

References System.Xml.XmlWellFormedWriter._currentState, System.Xml.XmlWellFormedWriter._rawWriter, System.Xml.XmlWellFormedWriter.AdvanceStateAsync(), System.Xml.ArgumentException, System.Xml.XmlWellFormedWriter.CheckNCName(), System.Threading.Tasks.Task< TResult >.ConfigureAwait(), System.SR.Format(), System.Xml.XmlWellFormedWriter.GeneratePrefix(), System.Xml.XmlWellFormedWriter.LookupPrefix(), System.Xml.XmlWellFormedWriter.PushNamespaceImplicit(), System.Xml.XmlWellFormedWriter.SaveAttrValue, System.text, System.Xml.XmlRawWriter.WriteQualifiedNameAsync(), System.Xml.XmlWellFormedWriter.WriteStringAsync(), System.SR.Xml_EmptyLocalName, and System.SR.Xml_UndefNamespace.