java.lang.Object
cloud.piranha.http.undertow.UndertowHttpServer
- All Implemented Interfaces:
HttpServer
The Undertow implementation of HTTP Server.
- Author:
- Manfred Riem ([email protected])
-
Constructor Summary
ConstructorDescriptionConstructor.UndertowHttpServer
(int serverPort) Constructor.UndertowHttpServer
(int serverPort, HttpServerProcessor httpServerProcessor) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionReturns the HTTP server processor.int
Returns the server port.boolean
getSSL()
Returns the SSL boolean flag.boolean
Is the server running?void
setHttpServerProcessor
(HttpServerProcessor httpServerProcessor) Set the HTTP server processor.void
setServerPort
(int serverPort) Set the server port.void
setSSL
(boolean ssl) Set the SSL boolean flag.void
start()
Start the server.void
stop()
Stops the server.
-
Constructor Details
-
UndertowHttpServer
public UndertowHttpServer()Constructor. -
UndertowHttpServer
public UndertowHttpServer(int serverPort) Constructor.- Parameters:
serverPort
- the server port.
-
UndertowHttpServer
Constructor.- Parameters:
serverPort
- the server port.httpServerProcessor
- the HTTP server processor.
-
-
Method Details
-
getHttpServerProcessor
Returns the HTTP server processor.- Specified by:
getHttpServerProcessor
in interfaceHttpServer
- Returns:
- the HTTP server processor
-
getSSL
public boolean getSSL()Returns the SSL boolean flag.- Specified by:
getSSL
in interfaceHttpServer
- Returns:
- the SSL boolean flag
-
getServerPort
public int getServerPort()Returns the server port.- Specified by:
getServerPort
in interfaceHttpServer
- Returns:
- the server port
-
isRunning
public boolean isRunning()Is the server running?- Specified by:
isRunning
in interfaceHttpServer
- Returns:
- true if running, false otherwise.
-
setHttpServerProcessor
Set the HTTP server processor.- Specified by:
setHttpServerProcessor
in interfaceHttpServer
- Parameters:
httpServerProcessor
- the HTTP server processor.
-
setSSL
public void setSSL(boolean ssl) Set the SSL boolean flag.- Specified by:
setSSL
in interfaceHttpServer
- Parameters:
ssl
- the SSL boolean flag.
-
setServerPort
public void setServerPort(int serverPort) Set the server port.- Specified by:
setServerPort
in interfaceHttpServer
- Parameters:
serverPort
- the server port.
-
start
public void start()Start the server.- Specified by:
start
in interfaceHttpServer
-
stop
public void stop()Stops the server.- Specified by:
stop
in interfaceHttpServer
-