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

◆ GetValueForTextOnlyColums()

string System.Data.XmlDataLoader.GetValueForTextOnlyColums ( XmlNode n)
inlineprivate

Definition at line 157 of file XmlDataLoader.cs.

158 {
159 string text = null;
160 while (n != null && (n.NodeType == XmlNodeType.Whitespace || !IsTextLikeNode(n.NodeType)))
161 {
162 n = n.NextSibling;
163 }
164 if (n != null)
165 {
166 if (IsTextLikeNode(n.NodeType) && (n.NextSibling == null || !IsTextLikeNode(n.NodeType)))
167 {
168 text = n.Value;
169 n = n.NextSibling;
170 }
171 else
172 {
174 while (n != null && IsTextLikeNode(n.NodeType))
175 {
176 stringBuilder.Append(n.Value);
177 n = n.NextSibling;
178 }
179 text = stringBuilder.ToString();
180 }
181 }
182 if (text == null)
183 {
184 text = string.Empty;
185 }
186 return text;
187 }
bool IsTextLikeNode(XmlNodeType n)

References System.Data.XmlDataLoader.IsTextLikeNode(), and System.text.

Referenced by System.Data.XmlDataLoader.LoadRowData().