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

◆ BeginGetConnection()

IAsyncResult System.Net.Mail.SmtpTransport.BeginGetConnection ( System::Net::ContextAwareResult outerResult,
AsyncCallback callback,
object state,
string host,
int port )
inlinepackage

Definition at line 126 of file SmtpTransport.cs.

127 {
128 IAsyncResult asyncResult = null;
129 try
130 {
131 _connection = new SmtpConnection(this, _client, _credentials, _authenticationModules);
132 if (System.Net.NetEventSource.Log.IsEnabled())
133 {
134 System.Net.NetEventSource.Associate(this, _connection, "BeginGetConnection");
135 }
136 if (EnableSsl)
137 {
138 _connection.EnableSsl = true;
139 _connection.ClientCertificates = ClientCertificates;
140 }
142 }
143 catch (Exception innerException)
144 {
145 throw new SmtpException(System.SR.MailHostNotFound, innerException);
146 }
147 if (System.Net.NetEventSource.Log.IsEnabled())
148 {
149 System.Net.NetEventSource.Info(this, "Sync completion", "BeginGetConnection");
150 }
151 return asyncResult;
152 }
IAsyncResult BeginGetConnection(System.Net.ContextAwareResult outerResult, AsyncCallback callback, object state, string host, int port)
ICredentialsByHost _credentials
X509CertificateCollection ClientCertificates
readonly SmtpClient _client
readonly ISmtpAuthenticationModule[] _authenticationModules
static readonly System.Net.NetEventSource Log
static void Info(object thisOrContextObject, FormattableString formattableString=null, [CallerMemberName] string memberName=null)
static void Associate(object first, object second, [CallerMemberName] string memberName=null)
static string MailHostNotFound
Definition SR.cs:170
Definition SR.cs:7

References System.Net.Mail.SmtpTransport._authenticationModules, System.Net.Mail.SmtpTransport._client, System.Net.Mail.SmtpTransport._connection, System.Net.Mail.SmtpTransport._credentials, System.Net.NetEventSource.Associate(), System.asyncResult, System.Net.Mail.SmtpConnection.BeginGetConnection(), System.Net.Mail.SmtpTransport.ClientCertificates, System.Net.Mail.SmtpTransport.EnableSsl, System.Net.NetEventSource.Info(), System.Net.NetEventSource.Log, System.SR.MailHostNotFound, and System.state.

Referenced by System.Net.Mail.SmtpClient.SendAsync().