3 instantiations of MailAddress
System.Net.Mail (3)
System\Net\Mail\MailAddress.cs (1)
110
result = new
MailAddress
(parsed.displayName, parsed.user, parsed.host, parsed.displayNameEncoding);
System\Net\Mail\MailAddressParser.cs (1)
44
results.Add(new
MailAddress
(parsedAddress.DisplayName, parsedAddress.User, parsedAddress.Host, null));
System\Net\Mail\MailPriority.cs (1)
52
_from = new
MailAddress
(from);
47 references to MailAddress
netstandard (1)
netstandard.cs (1)
1172
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Net.Mail.
MailAddress
))]
System (1)
src\libraries\shims\System\ref\System.cs (1)
657
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Net.Mail.
MailAddress
))]
System.Net.Mail (45)
System\Net\Mail\MailAddress.cs (12)
80
/// Create a new <see cref="
MailAddress
"/>. Does not throw an exception if the MailAddress cannot be created.
83
/// <param name="result">When this method returns, contains the <see cref="
MailAddress
"/> instance if address parsing succeed</param>
84
/// <returns>A <see cref="bool"/> value that is true if the <see cref="
MailAddress
"/> was successfully created; otherwise, false.</returns>
85
public static bool TryCreate([NotNullWhen(true)] string? address, [NotNullWhen(true)] out
MailAddress
? result) => TryCreate(address, displayName: null, out result);
88
/// Create a new <see cref="
MailAddress
"/>. Does not throw an exception if the MailAddress cannot be created.
92
/// <param name="result">When this method returns, contains the <see cref="
MailAddress
"/> instance if address parsing succeed</param>
93
/// <returns>A <see cref="bool"/> value that is true if the <see cref="
MailAddress
"/> was successfully created; otherwise, false.</returns>
94
public static bool TryCreate([NotNullWhen(true)] string? address, string? displayName, [NotNullWhen(true)] out
MailAddress
? result) => TryCreate(address, displayName, displayNameEncoding: null, out result);
97
/// Create a new <see cref="
MailAddress
"/>. Does not throw an exception if the MailAddress cannot be created.
102
/// <param name="result">When this method returns, contains the <see cref="
MailAddress
"/> instance if address parsing succeed</param>
103
/// <returns>A <see cref="bool"/> value that is true if the <see cref="
MailAddress
"/> was successfully created; otherwise, false.</returns>
104
public static bool TryCreate([NotNullWhen(true)] string? address, string? displayName, Encoding? displayNameEncoding, [NotNullWhen(true)] out
MailAddress
? result)
System\Net\Mail\MailAddressCollection.cs (5)
13
public class MailAddressCollection : Collection<
MailAddress
>
26
protected override void SetItem(int index,
MailAddress
item)
33
protected override void InsertItem(int index,
MailAddress
item)
42
List<
MailAddress
> result = MailAddressParser.ParseMultipleAddresses(addresses);
57
foreach (
MailAddress
address in this)
System\Net\Mail\MailAddressParser.cs (3)
37
internal static List<
MailAddress
> ParseMultipleAddresses(string data)
39
List<
MailAddress
> results = new List<
MailAddress
>();
System\Net\Mail\MailMessage.cs (5)
61
public MailMessage(
MailAddress
from,
MailAddress
to)
70
public
MailAddress
? From
84
public
MailAddress
? Sender
97
public
MailAddress
? ReplyTo
System\Net\Mail\MailPriority.cs (12)
24
private
MailAddress
? _from;
25
private
MailAddress
? _sender;
27
private
MailAddress
? _replyTo;
59
internal Message(
MailAddress
from,
MailAddress
to) : this()
82
internal
MailAddress
? From
96
internal
MailAddress
? Sender
109
internal
MailAddress
? ReplyTo
280
MailAddress
sender = Sender ?? From!;
287
foreach (
MailAddress
address in To)
291
foreach (
MailAddress
address in CC)
295
foreach (
MailAddress
address in Bcc)
System\Net\Mail\SmtpClient.cs (4)
462
foreach (
MailAddress
address in message.To)
469
foreach (
MailAddress
address in message.Bcc)
476
foreach (
MailAddress
address in message.CC)
725
foreach (
MailAddress
address in recipients)
System\Net\Mail\SmtpCommands.cs (2)
303
internal static Task SendAsync<TIOAdapter>(SmtpConnection conn, ReadOnlySpan<byte> command,
MailAddress
from, bool allowUnicode, CancellationToken cancellationToken = default)
340
private static void PrepareCommand(SmtpConnection conn, ReadOnlySpan<byte> command,
MailAddress
from, bool allowUnicode)
System\Net\Mail\SmtpTransport.cs (2)
112
internal async Task<(MailWriter, List<SmtpFailedRecipientException>?)> SendMailAsync<TIOAdapter>(
MailAddress
sender, MailAddressCollection recipients, string deliveryNotify, bool allowUnicode, CancellationToken cancellationToken = default)
121
foreach (
MailAddress
address in recipients)