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

◆ ToString() [2/2]

void System.Net.Cookie.ToString ( StringBuilder sb)
inlinepackage

Definition at line 614 of file Cookie.cs.

615 {
616 int length = sb.Length;
617 if (Version != 0)
618 {
619 sb.Append("$Version=");
620 if (IsQuotedVersion)
621 {
622 sb.Append('"');
623 }
626 handler.AppendFormatted(m_version);
627 sb.Append(invariantInfo, ref handler);
628 if (IsQuotedVersion)
629 {
630 sb.Append('"');
631 }
632 sb.Append("; ");
633 }
634 sb.Append(Name).Append('=').Append(Value);
635 if (!Plain)
636 {
637 if (!m_path_implicit && m_path.Length > 0)
638 {
639 sb.Append("; $Path=");
640 sb.Append(m_path);
641 }
642 if (!m_domain_implicit && m_domain.Length > 0)
643 {
644 sb.Append("; $Domain=");
645 if (IsQuotedDomain)
646 {
647 sb.Append('"');
648 }
649 sb.Append(m_domain);
650 if (IsQuotedDomain)
651 {
652 sb.Append('"');
653 }
654 }
655 }
656 if (!m_port_implicit)
657 {
658 sb.Append("; $Port");
659 if (m_port.Length > 0)
660 {
661 sb.Append('=');
662 sb.Append(m_port);
663 }
664 }
665 int length2 = sb.Length;
666 if (length2 == 1 + length && sb[length] == '=')
667 {
669 }
670 }
string m_path
Definition Cookie.cs:36
bool m_path_implicit
Definition Cookie.cs:38
bool IsQuotedDomain
Definition Cookie.cs:61
bool m_domain_implicit
Definition Cookie.cs:30
bool IsQuotedVersion
Definition Cookie.cs:59
bool m_port_implicit
Definition Cookie.cs:42
string m_domain
Definition Cookie.cs:28
string m_port
Definition Cookie.cs:40
StringBuilder Append(char value, int repeatCount)

References System.Text.StringBuilder.Append(), System.Text.StringBuilder.AppendInterpolatedStringHandler.AppendFormatted(), System.Runtime.Serialization.Dictionary, System.Globalization.NumberFormatInfo.InvariantInfo, System.Net.Cookie.IsQuotedDomain, System.Net.Cookie.IsQuotedVersion, System.length, System.Text.StringBuilder.Length, System.length2, System.Net.Cookie.m_domain, System.Net.Cookie.m_domain_implicit, System.Net.Cookie.m_path, System.Net.Cookie.m_path_implicit, System.Net.Cookie.m_port, System.Net.Cookie.m_port_implicit, System.Net.Cookie.m_version, System.Net.Cookie.Name, System.Net.Cookie.Plain, and System.Net.Cookie.Value.