org.jboss.resteasy.plugins.server.sun.http
Class SunHttpJaxrsServer
java.lang.Object
org.jboss.resteasy.plugins.server.sun.http.SunHttpJaxrsServer
- All Implemented Interfaces:
- EmbeddedJaxrsServer
public class SunHttpJaxrsServer
- extends Object
- implements EmbeddedJaxrsServer
com.sun.net.httpserver.HttpServer adapter for Resteasy. You may instead want to create and manage your own HttpServer.
Use the HttpContextBuilder class in this case to build and register a specific HttpContext.
- Version:
- $Revision: 1 $
- Author:
- Bill Burke
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
context
protected HttpContextBuilder context
httpServer
protected com.sun.net.httpserver.HttpServer httpServer
port
protected int port
SunHttpJaxrsServer
public SunHttpJaxrsServer()
setRootResourcePath
public void setRootResourcePath(String rootResourcePath)
- Specified by:
setRootResourcePath
in interface EmbeddedJaxrsServer
getDeployment
public ResteasyDeployment getDeployment()
- Specified by:
getDeployment
in interface EmbeddedJaxrsServer
setDeployment
public void setDeployment(ResteasyDeployment deployment)
- Specified by:
setDeployment
in interface EmbeddedJaxrsServer
setSecurityDomain
public void setSecurityDomain(SecurityDomain securityDomain)
- Setting a security domain will turn on Basic Authentication
- Specified by:
setSecurityDomain
in interface EmbeddedJaxrsServer
- Parameters:
securityDomain
-
setHttpServer
public void setHttpServer(com.sun.net.httpserver.HttpServer httpServer)
- If you do not provide an HttpServer instance, one will be created on startup
- Parameters:
httpServer
-
setPort
public void setPort(int port)
- Value is ignored if HttpServer property is set. Default value is 8080
- Parameters:
port
-
start
public void start()
- Specified by:
start
in interface EmbeddedJaxrsServer
stop
public void stop()
- Specified by:
stop
in interface EmbeddedJaxrsServer
Copyright © 2012. All Rights Reserved.