Coverage Report - net.sf.statsvn.util.SvnCommandHelper
 
Classes in this File Line Coverage Branch Coverage Complexity
SvnCommandHelper
0%
0/6
0%
0/2
1.5
 
 1  
 /**
 2  
  * 
 3  
  */
 4  
 package net.sf.statsvn.util;
 5  
 
 6  
 import net.sf.statsvn.output.SvnConfigurationOptions;
 7  
 
 8  
 /**
 9  
  * @author jpdaigle
 10  
  *
 11  
  * Utility class to help build svn command strings
 12  
  */
 13  
 public final class SvnCommandHelper {
 14  0
         private SvnCommandHelper() {
 15  0
         }
 16  
 
 17  
         /**
 18  
          * Gets the authentication / non-interactive command part to use when invoking
 19  
          * the subversion binary.
 20  
          * 
 21  
          * @return A String with the username, password and non-interactive settings
 22  
          */
 23  
         public static String getAuthString() {
 24  0
                 final StringBuffer strAuth = new StringBuffer(" --non-interactive");
 25  0
                 if (SvnConfigurationOptions.getSvnUsername() != null) {
 26  0
                         strAuth.append(" --username ").append(SvnConfigurationOptions.getSvnUsername()).append(" --password ").append(
 27  
                                 SvnConfigurationOptions.getSvnPassword());
 28  
                 }
 29  
 
 30  0
                 return strAuth.toString();
 31  
         }
 32  
 
 33  
 }