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

◆ Add() [2/3]

override void System.Net.Mime.HeaderCollection.Add ( string name,
string value )
inline

Definition at line 102 of file HeaderCollection.cs.

103 {
104 if (name == null)
105 {
106 throw new ArgumentNullException("name");
107 }
108 if (value == null)
109 {
110 throw new ArgumentNullException("value");
111 }
112 if (name.Length == 0)
113 {
114 throw new ArgumentException(System.SR.Format(System.SR.net_emptystringcall, "name"), "name");
115 }
116 if (value.Length == 0)
117 {
118 throw new ArgumentException(System.SR.Format(System.SR.net_emptystringcall, "value"), "value");
119 }
120 MailBnfHelper.ValidateHeaderName(name);
122 value = value.Normalize(NormalizationForm.FormC);
123 InternalAdd(name, value);
124 }
static string NormalizeCase(string name)
void InternalAdd(string name, string value)
static string Format(string resourceFormat, object p1)
Definition SR.cs:118
static string net_emptystringcall
Definition SR.cs:14
Definition SR.cs:7

References System.SR.Format(), System.Net.Mime.HeaderCollection.InternalAdd(), System.SR.net_emptystringcall, System.Net.Mail.MailHeaderInfo.NormalizeCase(), System.Net.Mime.MailBnfHelper.ValidateHeaderName(), and System.value.

Referenced by System.Net.Mail.Message.EncodeHeaders().