tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core StandardServer.java
Date Wed, 22 May 2002 22:17:24 GMT
remm        02/05/22 15:17:23

  Modified:    catalina/src/share/org/apache/catalina/core
                        StandardServer.java
  Log:
  - Add back the code specific to the ServerLifecycleListener.
    Otherwise, it wouldn't be part of the generated server.xml.
  
  Revision  Changes    Path
  1.26      +35 -35    jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardServer.java
  
  Index: StandardServer.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardServer.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- StandardServer.java	21 May 2002 01:36:36 -0000	1.25
  +++ StandardServer.java	22 May 2002 22:17:23 -0000	1.26
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardServer.java,v
1.25 2002/05/21 01:36:36 remm Exp $
  - * $Revision: 1.25 $
  - * $Date: 2002/05/21 01:36:36 $
  + * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/StandardServer.java,v
1.26 2002/05/22 22:17:23 remm Exp $
  + * $Revision: 1.26 $
  + * $Date: 2002/05/22 22:17:23 $
    *
    * ====================================================================
    *
  @@ -132,7 +132,7 @@
    * (but not required) when deploying and starting Catalina.
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.25 $ $Date: 2002/05/21 01:36:36 $
  + * @version $Revision: 1.26 $ $Date: 2002/05/22 22:17:23 $
    */
   
   public final class StandardServer
  @@ -192,7 +192,6 @@
           "org.apache.catalina.core.StandardContextValve",
           "org.apache.catalina.core.StandardEngineValve",
           "org.apache.catalina.core.StandardHostValve",
  -        "org.apache.catalina.mbeans.ServerLifecycleListener",
           "org.apache.catalina.startup.ContextConfig",
           "org.apache.catalina.startup.EngineConfig",
           "org.apache.catalina.startup.HostConfig",
  @@ -202,6 +201,13 @@
       };
   
   
  +    /**
  +     * ServerLifecycleListener classname.
  +     */
  +    private static String SERVER_LISTENER_CLASS_NAME = 
  +        "org.apache.catalina.mbeans.ServerLifecycleListener";
  +
  +
       // ------------------------------------------------------------ Constructor
   
   
  @@ -1040,11 +1046,10 @@
                   listeners = new LifecycleListener[0];
               }
               for (int i = 0; i < listeners.length; i++) {
  -                /*
  -                  if (listeners[i] instanceof ServerLifecycleListener) {
  -                  continue;
  -                  }
  -                */
  +                if (listeners[i].getClass().getName().equals
  +                    (SERVER_LISTENER_CLASS_NAME)) {
  +                    continue;
  +                }
                   storeListener(writer, indent + 2, listeners[i]);
               }
           }
  @@ -1094,11 +1099,10 @@
               LifecycleListener listeners[] =
                   ((Lifecycle) context).findLifecycleListeners();
               for (int i = 0; i < listeners.length; i++) {
  -                /*
  -                  if (listeners[i] instanceof ServerLifecycleListener) {
  -                  continue;
  -                  }
  -                */
  +                if (listeners[i].getClass().getName().equals
  +                    (SERVER_LISTENER_CLASS_NAME)) {
  +                    continue;
  +                }
                   storeListener(writer, indent + 2, listeners[i]);
               }
           }
  @@ -1238,11 +1242,10 @@
               LifecycleListener listeners[] =
                   ((Lifecycle) dcontext).findLifecycleListeners();
               for (int i = 0; i < listeners.length; i++) {
  -                /*
  -                  if (listeners[i] instanceof ServerLifecycleListener) {
  -                  continue;
  -                  }
  -                */
  +                if (listeners[i].getClass().getName().equals
  +                    (SERVER_LISTENER_CLASS_NAME)) {
  +                    continue;
  +                }
                   storeListener(writer, indent + 2, listeners[i]);
               }
           }
  @@ -1398,11 +1401,10 @@
               LifecycleListener listeners[] =
                   ((Lifecycle) engine).findLifecycleListeners();
               for (int i = 0; i < listeners.length; i++) {
  -                /*
  -                  if (listeners[i] instanceof ServerLifecycleListener) {
  -                  continue;
  -                  }
  -                */
  +                if (listeners[i].getClass().getName().equals
  +                    (SERVER_LISTENER_CLASS_NAME)) {
  +                    continue;
  +                }
                   storeListener(writer, indent + 2, listeners[i]);
               }
           }
  @@ -1538,11 +1540,10 @@
               LifecycleListener listeners[] =
                   ((Lifecycle) host).findLifecycleListeners();
               for (int i = 0; i < listeners.length; i++) {
  -                /*
  -                  if (listeners[i] instanceof ServerLifecycleListener) {
  -                  continue;
  -                  }
  -                */
  +                if (listeners[i].getClass().getName().equals
  +                    (SERVER_LISTENER_CLASS_NAME)) {
  +                    continue;
  +                }
                   storeListener(writer, indent + 2, listeners[i]);
               }
           }
  @@ -2001,11 +2002,10 @@
               LifecycleListener listeners[] =
                   ((Lifecycle) service).findLifecycleListeners();
               for (int i = 0; i < listeners.length; i++) {
  -                /*
  -                  if (listeners[i] instanceof ServerLifecycleListener) {
  -                  continue;
  -                  }
  -                */
  +                if (listeners[i].getClass().getName().equals
  +                    (SERVER_LISTENER_CLASS_NAME)) {
  +                    continue;
  +                }
                   storeListener(writer, indent + 2, listeners[i]);
               }
           }
  
  
  

--
To unsubscribe, e-mail:   <mailto:tomcat-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-dev-help@jakarta.apache.org>


Mime
View raw message