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

◆ WriteWithReplace()

void System.Xml.Xsl.XsltOld.SequentialOutput.WriteWithReplace ( string value,
char[] find,
string[] replace )
inlineprivateinherited

Definition at line 533 of file SequentialOutput.cs.

534 {
535 int length = value.Length;
536 int i;
537 for (i = 0; i < length; i++)
538 {
539 int num = value.IndexOfAny(find, i);
540 if (num == -1)
541 {
542 break;
543 }
544 for (; i < num; i++)
545 {
546 Write(value[i]);
547 }
548 char c = value[i];
549 int num2 = find.Length - 1;
550 while (0 <= num2)
551 {
552 if (find[num2] == c)
553 {
555 break;
556 }
557 num2--;
558 }
559 }
560 if (i == 0)
561 {
562 Write(value);
563 return;
564 }
565 for (; i < length; i++)
566 {
567 Write(value[i]);
568 }
569 }

References System.Xml.Dictionary, System.length, System.value, and System.Xml.Xsl.XsltOld.SequentialOutput.Write().

Referenced by System.Xml.Xsl.XsltOld.SequentialOutput.WriteTextNode(), and System.Xml.Xsl.XsltOld.SequentialOutput.WriteXmlAttributeValue().