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

◆ WriteEscapedText() [1/3]

void System.Xml.XmlCanonicalWriter.WriteEscapedText ( byte[] chars,
int offset,
int count )
inline

Definition at line 700 of file XmlCanonicalWriter.cs.

701 {
702 if (chars == null)
703 {
704 throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentNullException("chars"));
705 }
706 if (offset < 0)
707 {
708 throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("offset", System.SR.ValueMustBeNonNegative));
709 }
710 if (offset > chars.Length)
711 {
712 throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("offset", System.SR.Format(System.SR.OffsetExceedsBufferSize, chars.Length)));
713 }
714 if (count < 0)
715 {
716 throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("count", System.SR.ValueMustBeNonNegative));
717 }
718 if (count > chars.Length - offset)
719 {
720 throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ArgumentOutOfRangeException("count", System.SR.Format(System.SR.SizeExceedsRemainingBufferSpace, chars.Length - offset)));
721 }
723 if (_depth > 0)
724 {
725 if (_inStartElement)
726 {
728 }
729 else
730 {
732 }
733 }
734 }
static string Format(string resourceFormat, object p1)
Definition SR.cs:118
static string ValueMustBeNonNegative
Definition SR.cs:296
static string SizeExceedsRemainingBufferSpace
Definition SR.cs:324
static string OffsetExceedsBufferSize
Definition SR.cs:322
Definition SR.cs:7
override void WriteEscapedText(XmlDictionaryString s)

References System.Xml.XmlCanonicalWriter._depth, System.Xml.XmlCanonicalWriter._elementWriter, System.Xml.XmlCanonicalWriter._inStartElement, System.Xml.XmlCanonicalWriter._writer, System.chars, System.count, System.SR.Format(), System.offset, System.SR.OffsetExceedsBufferSize, System.SR.SizeExceedsRemainingBufferSpace, System.Runtime.Serialization.DiagnosticUtility.ExceptionUtility.ThrowHelperError(), System.Xml.XmlCanonicalWriter.ThrowIfClosed(), System.SR.ValueMustBeNonNegative, and System.Xml.XmlUTF8NodeWriter.WriteEscapedText().