public class SMTPAuthenticator
extends javax.mail.Authenticator
Authenticator
object that can be used to authenticate
with an SMTP server prior to attempting to send mail through the server.Authenticator
,
PasswordAuthentication
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
COPYRIGHT
Copyright.
|
Constructor and Description |
---|
SMTPAuthenticator(java.lang.String account,
java.lang.String pwd)
SMTPAuthenicator constructor.
|
Modifier and Type | Method and Description |
---|---|
javax.mail.PasswordAuthentication |
getPasswordAuthentication()
Gets a PasswordAuthenication object based on the parameters passed to the
contructor.
|
public static final java.lang.String COPYRIGHT
public SMTPAuthenticator(java.lang.String account, java.lang.String pwd)
account
- The user account name to usepwd
- The user password name to usepublic javax.mail.PasswordAuthentication getPasswordAuthentication()
getPasswordAuthentication
in class javax.mail.Authenticator