Coverage Report - org.mule.transport.email.DefaultAuthenticator
 
Classes in this File Line Coverage Branch Coverage Complexity
DefaultAuthenticator
0%
0/7
N/A
1
 
 1  
 /*
 2  
  * Copyright (c) MuleSoft, Inc.  All rights reserved.  http://www.mulesoft.com
 3  
  * The software in this package is published under the terms of the CPAL v1.0
 4  
  * license, a copy of which has been included with this distribution in the
 5  
  * LICENSE.txt file.
 6  
  */
 7  
 package org.mule.transport.email;
 8  
 
 9  
 import javax.mail.PasswordAuthentication;
 10  
 
 11  
 /**
 12  
  * DefaultAuthenticator is used to do simple authentication when the SMTP server
 13  
  * requires it.
 14  
  */
 15  
 class DefaultAuthenticator extends javax.mail.Authenticator
 16  
 {
 17  0
     private String username = null;
 18  0
     private String password = null;
 19  
 
 20  
     public DefaultAuthenticator(String user, String pwd)
 21  0
     {
 22  0
         username = user;
 23  0
         password = pwd;
 24  0
     }
 25  
 
 26  
     public PasswordAuthentication getPasswordAuthentication()
 27  
     {
 28  0
         return new PasswordAuthentication(username, password);
 29  
     }
 30  
 }