クラス
javax.mail.Authenticator の使用

Authenticator を使用しているパッケージ
javax.mail メールシステムをモデル化するクラスです。 
 

javax.mail での Authenticator の使用
 

Authenticator 型のパラメータを持つ javax.mail のメソッド
static Session Session.getDefaultInstance(Properties props, Authenticator authenticator)
          デフォルトの Session オブジェクトを取得します。
static Session Session.getInstance(Properties props, Authenticator authenticator)
          新しい Session オブジェクトを取得します。