User: user57
Date: 01/08/22 17:06:00
Modified: jetty/src/main/org/jboss/jetty SetupHandler.java
Log:
o added empty handle(String, HttpRequest, HttpResponse) so this will compile
based on the version of jetty in thridparty.
Revision Changes Path
1.7 +63 -44 contrib/jetty/src/main/org/jboss/jetty/SetupHandler.java
Index: SetupHandler.java
===================================================================
RCS file: /cvsroot/jboss/contrib/jetty/src/main/org/jboss/jetty/SetupHandler.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- SetupHandler.java 2001/08/22 20:02:34 1.6
+++ SetupHandler.java 2001/08/23 00:06:00 1.7
@@ -1,71 +1,90 @@
package org.jboss.jetty;
+import java.io.IOException;
+
import com.mortbay.HTTP.Handler.NullHandler;
import com.mortbay.HTTP.HandlerContext;
import com.mortbay.HTTP.HttpException;
import com.mortbay.HTTP.HttpRequest;
import com.mortbay.HTTP.HttpResponse;
import com.mortbay.HTTP.HttpServer;
-import java.io.IOException;
+
import org.apache.log4j.Category;
+
import org.jboss.web.AbstractWebContainer.WebDescriptorParser;
import org.jboss.web.WebApplication;
+
import org.w3c.dom.Element;
-/** An HttpHandler that simply hooks into the web application startup
+/**
+ * An HttpHandler that simply hooks into the web application startup
* so that is sees the correct class loader and security realm name.
*
* @author [EMAIL PROTECTED]
- * @version $Revision: 1.6 $
+ * @version $Revision: 1.7 $
*/
public class SetupHandler
- extends NullHandler
+ extends NullHandler
{
- Category _log;
- WebDescriptorParser _descriptorParser;
- WebApplication _webApp;
-
- //----------------------------------------------------------------------
-
- public
- SetupHandler(Category log,
- WebDescriptorParser descriptorParser, WebApplication webApp)
- {
- _log = log;
- _descriptorParser = descriptorParser;
- _webApp = webApp;
- }
+ Category _log;
+ WebDescriptorParser _descriptorParser;
+ WebApplication _webApp;
+
+ //----------------------------------------------------------------------
+
+ public SetupHandler(Category log,
+ WebDescriptorParser descriptorParser,
+ WebApplication webApp)
+ {
+ _log = log;
+ _descriptorParser = descriptorParser;
+ _webApp = webApp;
+ }
- //----------------------------------------------------------------------
+ //----------------------------------------------------------------------
- public void
- start()
- throws Exception
- {
- ClassLoader loader = getHandlerContext().getClassLoader();
- if (_webApp.getClassLoader()!=loader.getParent())
- _log.warn("WARNING: WebApp ClassLoader is not child of J2EEDeployer's
ClassLoader");
+ public void start() throws Exception
+ {
+ ClassLoader loader = getHandlerContext().getClassLoader();
+ if (_webApp.getClassLoader()!=loader.getParent()) {
+ _log.warn("WebApp ClassLoader is not child of J2EEDeployer's ClassLoader");
+ }
- // Setup the JNDI environment
- Element webAppDD = _webApp.getWebApp();
- Element jbossDD = _webApp.getJbossWeb();
- _descriptorParser.parseWebAppDescriptors(loader, webAppDD, jbossDD);
+ // Setup the JNDI environment
+ Element webAppDD = _webApp.getWebApp();
+ Element jbossDD = _webApp.getJbossWeb();
+ _descriptorParser.parseWebAppDescriptors(loader, webAppDD, jbossDD);
- // Add the JBoss security realm
- HttpServer server = getHandlerContext().getHttpServer();
- String realmName = getHandlerContext().getRealm();
- server.addRealm(new JBossUserRealm(_log, realmName));
+ // Add the JBoss security realm
+ HttpServer server = getHandlerContext().getHttpServer();
+ String realmName = getHandlerContext().getRealm();
+ server.addRealm(new JBossUserRealm(_log, realmName));
- super.start();
- }
+ super.start();
+ }
- //----------------------------------------------------------------------
-
- // does nothing - we are only interested in start()...
+ //----------------------------------------------------------------------
- public void
- handle(String pathInContext, String pathParams, HttpRequest request,
HttpResponse response)
- throws HttpException, IOException
- {
- }
+ /**
+ * Does nothing - we are only interested in {@link #start}.
+ */
+ public void handle(String pathInContext,
+ String pathParams,
+ HttpRequest request,
+ HttpResponse response)
+
+ throws HttpException, IOException
+ {
+ }
+
+ /**
+ * Does nothing - we are only interested in {@link #start}.
+ */
+ public void handle(String pathInContext,
+ HttpRequest request,
+ HttpResponse response)
+
+ throws HttpException, IOException
+ {
+ }
}
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development