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

◆ TryParseDomain()

static bool System.Net.Mail.MailAddressParser.TryParseDomain ( string data,
ref int index,
[NotNullWhen(true)] out string domain,
bool throwExceptionIfFail )
inlinestaticprivate

Definition at line 115 of file MailAddressParser.cs.

116 {
118 {
119 domain = null;
120 return false;
121 }
122 int num = index;
123 if (data[index] == ']')
124 {
125 if (!DomainLiteralReader.TryReadReverse(data, index, out index, throwExceptionIfFail))
126 {
127 domain = null;
128 return false;
129 }
130 }
131 else if (!DotAtomReader.TryReadReverse(data, index, out index, throwExceptionIfFail))
132 {
133 domain = null;
134 return false;
135 }
136 domain = data.Substring(index + 1, num - index);
138 {
139 return false;
140 }
142 {
143 return false;
144 }
145 return true;
146 }
static bool TryReadCfwsAndThrowIfIncomplete(string data, int index, out int outIndex, bool throwExceptionIfFail)
static bool TryNormalizeOrThrow(string input, [NotNullWhen(true)] out string normalizedString, bool throwExceptionIfFail)

References System.index, System.Net.Mail.MailAddressParser.TryNormalizeOrThrow(), System.Net.Mail.MailAddressParser.TryReadCfwsAndThrowIfIncomplete(), System.Net.Mail.DomainLiteralReader.TryReadReverse(), and System.Net.Mail.DotAtomReader.TryReadReverse().

Referenced by System.Net.Mail.MailAddressParser.TryParseAddress().