org.jboss.msc.services.http
Class HttpContextService
java.lang.Object
org.jboss.msc.services.http.HttpContextService
- All Implemented Interfaces:
- Service<com.sun.net.httpserver.HttpContext>, Value<com.sun.net.httpserver.HttpContext>
public final class HttpContextService
- extends Object
- implements Service<com.sun.net.httpserver.HttpContext>
An HTTP context.
- Author:
- David M. Lloyd
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SERVER_SETTER
public static final Value<Method> SERVER_SETTER
HANDLER_SETTER
public static final Value<Method> HANDLER_SETTER
PATH_SETTER
public static final Value<Method> PATH_SETTER
httpServerInjector
public final Injector<com.sun.net.httpserver.HttpServer> httpServerInjector
httpHandlerInjector
public final Injector<com.sun.net.httpserver.HttpHandler> httpHandlerInjector
pathInjector
public final Injector<String> pathInjector
HttpContextService
public HttpContextService()
getPath
public String getPath()
setPath
public void setPath(String path)
getHandler
public com.sun.net.httpserver.HttpHandler getHandler()
setHandler
public void setHandler(com.sun.net.httpserver.HttpHandler handler)
getServer
public com.sun.net.httpserver.HttpServer getServer()
setServer
public void setServer(com.sun.net.httpserver.HttpServer server)
start
public void start(StartContext context)
throws StartException
- Description copied from interface:
Service
- Start the service. Do not return until the service has been fully started, unless an asynchronous service
start is performed. All injections will be complete before this method is called.
- Specified by:
start in interface Service<com.sun.net.httpserver.HttpContext>
- Parameters:
context - the context which can be used to trigger an asynchronous service start
- Throws:
StartException - if the service could not be started for some reason
stop
public void stop(StopContext context)
- Description copied from interface:
Service
- Stop the service. Do not return until the service has been fully stopped, unless an asynchronous service
stop is performed. All injections will remain intact until the service is fully stopped. This method should
not throw an exception.
- Specified by:
stop in interface Service<com.sun.net.httpserver.HttpContext>
- Parameters:
context - the context which can be used to trigger an asynchronous service stop
getValue
public com.sun.net.httpserver.HttpContext getValue()
throws IllegalStateException
- Description copied from interface:
Value
- Get the actual value.
- Specified by:
getValue in interface Value<com.sun.net.httpserver.HttpContext>
- Returns:
- the actual value
- Throws:
IllegalStateException - if the value is time-sensitive and the current state does not allow retrieval.
Copyright © 2010 JBoss, a division of Red Hat, Inc.