vmassol     02/04/14 03:46:25

  Modified:    framework/src/java/share/org/apache/cactus
                        AbstractTestCase.java ServiceDefinition.java
                        ServletURL.java WebRequest.java
               framework/src/java/share/org/apache/cactus/client
                        HttpClientHelper.java
               framework/src/java/share/org/apache/cactus/client/authentication
                        BasicAuthentication.java
               framework/src/java/share/org/apache/cactus/server
                        AbstractTestCaller.java ServletTestRedirector.java
               framework/src/java/share/org/apache/cactus/util
                        JUnitVersionHelper.java
               framework/src/test/share/org/apache/cactus
                        TestAbstractTestCase.java TestServletURL.java
                        TestServletUtil.java
  Log:
  corrected checkstyle reported errors
  
  Revision  Changes    Path
  1.2       +5 -5      
jakarta-cactus/framework/src/java/share/org/apache/cactus/AbstractTestCase.java
  
  Index: AbstractTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/AbstractTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AbstractTestCase.java     1 Mar 2002 00:43:45 -0000       1.1
  +++ AbstractTestCase.java     14 Apr 2002 10:46:25 -0000      1.2
  @@ -78,29 +78,29 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: AbstractTestCase.java,v 1.1 2002/03/01 00:43:45 vmassol Exp $
  + * @version $Id: AbstractTestCase.java,v 1.2 2002/04/14 10:46:25 vmassol Exp $
    */
   public abstract class AbstractTestCase extends TestCase
   {
       /**
        * The prefix of a test method.
        */
  -    protected final static String TEST_METHOD_PREFIX = "test";
  +    protected static final String TEST_METHOD_PREFIX = "test";
   
       /**
        * The prefix of a begin test method.
        */
  -    protected final static String BEGIN_METHOD_PREFIX = "begin";
  +    protected static final String BEGIN_METHOD_PREFIX = "begin";
   
       /**
        * The prefix of an end test method.
        */
  -    protected final static String END_METHOD_PREFIX = "end";
  +    protected static final String END_METHOD_PREFIX = "end";
   
       /**
        * Name of properties file to initialize logging subsystem
        */
  -    public final static String LOG_CLIENT_CONFIG = "log_client.properties";
  +    public static final String LOG_CLIENT_CONFIG = "log_client.properties";
   
       /**
        * The name of the current test method being executed. This name is valid
  
  
  
  1.2       +5 -5      
jakarta-cactus/framework/src/java/share/org/apache/cactus/ServiceDefinition.java
  
  Index: ServiceDefinition.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/ServiceDefinition.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ServiceDefinition.java    1 Mar 2002 00:43:45 -0000       1.1
  +++ ServiceDefinition.java    14 Apr 2002 10:46:25 -0000      1.2
  @@ -62,7 +62,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: ServiceDefinition.java,v 1.1 2002/03/01 00:43:45 vmassol Exp $
  + * @version $Id: ServiceDefinition.java,v 1.2 2002/04/14 10:46:25 vmassol Exp $
    */
   public class ServiceDefinition
   {
  @@ -71,7 +71,7 @@
        * Test class to call. The name is voluntarily long so that it will not
        * clash with a user-defined parameter.
        */
  -    public final static String CLASS_NAME_PARAM =
  +    public static final String CLASS_NAME_PARAM =
           "Cactus_TestClass";
   
       /**
  @@ -79,14 +79,14 @@
        * Test method to call. The name is voluntarily long so that it will not
        * clash with a user-defined parameter.
        */
  -    public final static String METHOD_NAME_PARAM =
  +    public static final String METHOD_NAME_PARAM =
           "Cactus_TestMethod";
   
       /**
        * Name of the parameter in the HTTP request that specify if a session
        * should be automatically created for the user or not.
        */
  -    public final static String AUTOSESSION_NAME_PARAM =
  +    public static final String AUTOSESSION_NAME_PARAM =
           "Cactus_AutomaticSession";
   
       /**
  @@ -97,7 +97,7 @@
        *
        * @see ServiceEnumeration
        */
  -    public final static String SERVICE_NAME_PARAM =
  +    public static final String SERVICE_NAME_PARAM =
           "Cactus_Service";
   
   }
  
  
  
  1.3       +10 -10    
jakarta-cactus/framework/src/java/share/org/apache/cactus/ServletURL.java
  
  Index: ServletURL.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/ServletURL.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ServletURL.java   28 Mar 2002 16:03:03 -0000      1.2
  +++ ServletURL.java   14 Apr 2002 10:46:25 -0000      1.3
  @@ -65,7 +65,7 @@
   /**
    * Simulate an HTTP URL by breaking it into its different parts :<br>
    * <code><pre><b>
  - * URL        = "http://"; + serverName (including port) + requestURI ? 
queryString<br>
  + * URL = "http://"; + serverName (including port) + requestURI ? queryString<br>
    * requestURI = contextPath + servletPath + pathInfo
    * </b></pre></code>
    * From the Servlet 2.2 specification :<br>
  @@ -82,7 +82,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: ServletURL.java,v 1.2 2002/03/28 16:03:03 vmassol Exp $
  + * @version $Id: ServletURL.java,v 1.3 2002/04/14 10:46:25 vmassol Exp $
    */
   public class ServletURL
   {
  @@ -91,7 +91,7 @@
        * (HTTP, HTTPS, etc) in the URL to simulate. The name is voluntarily long
        * so that it will not clash with a user-defined parameter.
        */
  -    public final static String URL_PROTOCOL_PARAM =
  +    public static final String URL_PROTOCOL_PARAM =
           "Cactus_URL_Protocol";
   
       /**
  @@ -99,7 +99,7 @@
        * name (+ port) in the URL to simulate. The name is voluntarily long so
        * that it will not clash with a user-defined parameter.
        */
  -    public final static String URL_SERVER_NAME_PARAM =
  +    public static final String URL_SERVER_NAME_PARAM =
           "Cactus_URL_Server";
   
       /**
  @@ -107,7 +107,7 @@
        * path in the URL to simulate. The name is voluntarily long so that it
        * will not clash with a user-defined parameter.
        */
  -    public final static String URL_CONTEXT_PATH_PARAM =
  +    public static final String URL_CONTEXT_PATH_PARAM =
           "Cactus_URL_ContextPath";
   
       /**
  @@ -115,7 +115,7 @@
        * Path in the URL to simulate. The name is voluntarily long so that it
        * will not clash with a user-defined parameter.
        */
  -    public final static String URL_SERVLET_PATH_PARAM =
  +    public static final String URL_SERVLET_PATH_PARAM =
           "Cactus_URL_ServletPath";
   
       /**
  @@ -123,7 +123,7 @@
        * in the URL to simulate. The name is voluntarily long so that it will not
        * clash with a user-defined parameter.
        */
  -    public final static String URL_PATH_INFO_PARAM =
  +    public static final String URL_PATH_INFO_PARAM =
           "Cactus_URL_PathInfo";
   
       /**
  @@ -131,18 +131,18 @@
        * String in the URL to simulate. The name is voluntarily long so that it
        * will not clash with a user-defined parameter.
        */
  -    public final static String URL_QUERY_STRING_PARAM =
  +    public static final String URL_QUERY_STRING_PARAM =
           "Cactus_URL_QueryString";
   
       /**
        * Http protocol.
        */
  -    public final static String PROTOCOL_HTTP = "http";
  +    public static final String PROTOCOL_HTTP = "http";
   
       /**
        * Https protocol.
        */
  -    public final static String PROTOCOL_HTTPS = "https";
  +    public static final String PROTOCOL_HTTPS = "https";
   
       /**
        * The server name to simulate (including port number)
  
  
  
  1.2       +3 -3      
jakarta-cactus/framework/src/java/share/org/apache/cactus/WebRequest.java
  
  Index: WebRequest.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/WebRequest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- WebRequest.java   1 Mar 2002 00:43:45 -0000       1.1
  +++ WebRequest.java   14 Apr 2002 10:46:25 -0000      1.2
  @@ -92,7 +92,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Jason Robertson</a>
    *
  - * @version $Id: WebRequest.java,v 1.1 2002/03/01 00:43:45 vmassol Exp $
  + * @version $Id: WebRequest.java,v 1.2 2002/04/14 10:46:25 vmassol Exp $
    */
   public class WebRequest
   {
  @@ -254,8 +254,8 @@
       /**
        * Sets the simulated URL. A URL is of the form :<br>
        * <code><pre><b>
  -     * URL        = "http://"; + serverName (including port) + requestURI ? 
queryString<br>
  -     * requestURI = contextPath + servletPath + pathInfo
  +     * URL = "http://"; + serverName (including port) + requestURI ? queryString
  +     * <br>requestURI = contextPath + servletPath + pathInfo
        * </b></pre></code>
        * From the Servlet 2.2 specification :<br>
        * <code><pre><ul>
  
  
  
  1.3       +4 -6      
jakarta-cactus/framework/src/java/share/org/apache/cactus/client/HttpClientHelper.java
  
  Index: HttpClientHelper.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/client/HttpClientHelper.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- HttpClientHelper.java     24 Mar 2002 16:52:53 -0000      1.2
  +++ HttpClientHelper.java     14 Apr 2002 10:46:25 -0000      1.3
  @@ -84,7 +84,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Jason Robertson</a>
    *
  - * @version $Id: HttpClientHelper.java,v 1.2 2002/03/24 16:52:53 vmassol Exp $
  + * @version $Id: HttpClientHelper.java,v 1.3 2002/04/14 10:46:25 vmassol Exp $
    */
   public class HttpClientHelper
   {
  @@ -100,13 +100,10 @@
       private String url;
   
       // Static initialisations
  -    static
  -    {
  -
  +    static {
           // Do not follow redirects (because we are doing unit tests and
           // we need to be able to assert the returned headers, cookies, ...)
           HttpURLConnection.setFollowRedirects(false);
  -
       }
   
       /**
  @@ -373,7 +370,8 @@
                   // If no domain has been specified, use a default one
                   String domain;
                   if (cactusCookie.getDomain() == null) {
  -                    domain = HttpClientHelper.getDomain(theRequest, theConnection);
  +                    domain = HttpClientHelper.getDomain(theRequest,
  +                        theConnection);
                   } else {
                       domain = cactusCookie.getDomain();
                   }
  
  
  
  1.2       +2 -3      
jakarta-cactus/framework/src/java/share/org/apache/cactus/client/authentication/BasicAuthentication.java
  
  Index: BasicAuthentication.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/client/authentication/BasicAuthentication.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BasicAuthentication.java  1 Mar 2002 00:43:46 -0000       1.1
  +++ BasicAuthentication.java  14 Apr 2002 10:46:25 -0000      1.2
  @@ -69,7 +69,7 @@
    * @since 1.3
    * @see AbstractAuthentication
    *
  - * @version $Id: BasicAuthentication.java,v 1.1 2002/03/01 00:43:46 vmassol Exp $
  + * @version $Id: BasicAuthentication.java,v 1.2 2002/04/14 10:46:25 vmassol Exp $
    */
   public class BasicAuthentication extends AbstractAuthentication
   {
  @@ -86,8 +86,7 @@
        */
       private static byte[] codes = new byte[256];
   
  -    static
  -    {
  +    static {
           for (int i = 0; i < 256; i++) {
               codes[i] = -1;
           }
  
  
  
  1.4       +3 -3      
jakarta-cactus/framework/src/java/share/org/apache/cactus/server/AbstractTestCaller.java
  
  Index: AbstractTestCaller.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/server/AbstractTestCaller.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- AbstractTestCaller.java   10 Mar 2002 18:27:26 -0000      1.3
  +++ AbstractTestCaller.java   14 Apr 2002 10:46:25 -0000      1.4
  @@ -76,7 +76,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Nicholas Lesiecki</a>
    *
  - * @version $Id: AbstractTestCaller.java,v 1.3 2002/03/10 18:27:26 vmassol Exp $
  + * @version $Id: AbstractTestCaller.java,v 1.4 2002/04/14 10:46:25 vmassol Exp $
    */
   public abstract class AbstractTestCaller
   {
  @@ -84,7 +84,7 @@
        * Name of the attribute in the <code>application</code> scope that will
        * hold the results of the test.
        */
  -    private final static String TEST_RESULTS =
  +    private static final String TEST_RESULTS =
           "ServletTestRedirector_TestResults";
   
       /**
  @@ -369,7 +369,7 @@
       private ClassLoader getAppropriateClassLoader()
       {
           ClassLoader loader = Thread.currentThread().getContextClassLoader();
  -        if(loader == null) {
  +        if (loader == null) {
               loader = this.getClass().getClassLoader();
           }
           return loader;
  
  
  
  1.2       +2 -3      
jakarta-cactus/framework/src/java/share/org/apache/cactus/server/ServletTestRedirector.java
  
  Index: ServletTestRedirector.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/server/ServletTestRedirector.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ServletTestRedirector.java        1 Mar 2002 00:43:46 -0000       1.1
  +++ ServletTestRedirector.java        14 Apr 2002 10:46:25 -0000      1.2
  @@ -69,7 +69,7 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: ServletTestRedirector.java,v 1.1 2002/03/01 00:43:46 vmassol Exp $
  + * @version $Id: ServletTestRedirector.java,v 1.2 2002/04/14 10:46:25 vmassol Exp $
    * @see ServletTestCaller
    */
   public class ServletTestRedirector extends HttpServlet
  @@ -79,8 +79,7 @@
        * details from the correct properties file. Initialization is done here
        * as this servlet is the first point of entry to the server code.
        */
  -    static
  -    {
  +    static {
           LogService.getInstance().init("/log_server.properties");
       }
   
  
  
  
  1.2       +3 -4      
jakarta-cactus/framework/src/java/share/org/apache/cactus/util/JUnitVersionHelper.java
  
  Index: JUnitVersionHelper.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/java/share/org/apache/cactus/util/JUnitVersionHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- JUnitVersionHelper.java   1 Mar 2002 00:43:47 -0000       1.1
  +++ JUnitVersionHelper.java   14 Apr 2002 10:46:25 -0000      1.2
  @@ -67,7 +67,7 @@
    * @author <a href="mailto:[EMAIL PROTECTED]";>Stefan Bodewig</a>
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: JUnitVersionHelper.java,v 1.1 2002/03/01 00:43:47 vmassol Exp $
  + * @version $Id: JUnitVersionHelper.java,v 1.2 2002/04/14 10:46:25 vmassol Exp $
    */
   public class JUnitVersionHelper
   {
  @@ -77,8 +77,7 @@
        */
       private static Method testCaseName = null;
   
  -    static
  -    {
  +    static {
           try {
               testCaseName = TestCase.class.getMethod("getName", new Class[0]);
           } catch (NoSuchMethodException e) {
  @@ -86,7 +85,7 @@
               try {
                   testCaseName = TestCase.class.getMethod("name", new Class[0]);
               } catch (NoSuchMethodException e2) {
  -                throw new ChainedRuntimeException("Cannot find method 'name()'");
  +                throw new ChainedRuntimeException("Cannot find method name()");
               }
           }
       }
  
  
  
  1.3       +2 -3      
jakarta-cactus/framework/src/test/share/org/apache/cactus/TestAbstractTestCase.java
  
  Index: TestAbstractTestCase.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/test/share/org/apache/cactus/TestAbstractTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- TestAbstractTestCase.java 10 Apr 2002 00:37:17 -0000      1.2
  +++ TestAbstractTestCase.java 14 Apr 2002 10:46:25 -0000      1.3
  @@ -68,14 +68,13 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: TestAbstractTestCase.java,v 1.2 2002/04/10 00:37:17 vmassol Exp $
  + * @version $Id: TestAbstractTestCase.java,v 1.3 2002/04/14 10:46:25 vmassol Exp $
    */
   public class TestAbstractTestCase extends
       TestAbstractTestCase_InterceptorTestCase
   {
       // Initialize logging system first
  -    static
  -    {
  +    static {
           LogService.getInstance().init(null);
       }
   
  
  
  
  1.3       +2 -3      
jakarta-cactus/framework/src/test/share/org/apache/cactus/TestServletURL.java
  
  Index: TestServletURL.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/test/share/org/apache/cactus/TestServletURL.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- TestServletURL.java       10 Apr 2002 00:37:17 -0000      1.2
  +++ TestServletURL.java       14 Apr 2002 10:46:25 -0000      1.3
  @@ -67,13 +67,12 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: TestServletURL.java,v 1.2 2002/04/10 00:37:17 vmassol Exp $
  + * @version $Id: TestServletURL.java,v 1.3 2002/04/14 10:46:25 vmassol Exp $
    */
   public class TestServletURL extends TestCase
   {
       // Initialize logging system first
  -    static
  -    {
  +    static {
           LogService.getInstance().init(null);
       }
   
  
  
  
  1.3       +2 -3      
jakarta-cactus/framework/src/test/share/org/apache/cactus/TestServletUtil.java
  
  Index: TestServletUtil.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-cactus/framework/src/test/share/org/apache/cactus/TestServletUtil.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- TestServletUtil.java      10 Apr 2002 00:37:17 -0000      1.2
  +++ TestServletUtil.java      14 Apr 2002 10:46:25 -0000      1.3
  @@ -68,13 +68,12 @@
    *
    * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
    *
  - * @version $Id: TestServletUtil.java,v 1.2 2002/04/10 00:37:17 vmassol Exp $
  + * @version $Id: TestServletUtil.java,v 1.3 2002/04/14 10:46:25 vmassol Exp $
    */
   public class TestServletUtil extends TestCase
   {
       // Initialize logging system first
  -    static
  -    {
  +    static {
           LogService.getInstance().init(null);
       }
   
  
  
  

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to