public class HttpBootstrap extends Object
| Constructor and Description |
|---|
HttpBootstrap() |
HttpBootstrap(HttpMessageProcessor processor) |
| Modifier and Type | Method and Description |
|---|---|
HttpServerConfiguration |
configuration()
服务配置
|
HttpBootstrap |
httpHandler(HttpServerHandler httpHandler)
往 http 处理器管道中注册 Handle
|
HttpBootstrap |
setPort(int port)
Http服务端口号
|
void |
shutdown()
停止服务
|
void |
start()
启动HTTP服务
|
HttpBootstrap |
webSocketHandler(WebSocketHandler webSocketHandler)
获取websocket的处理器管道
|
public HttpBootstrap()
public HttpBootstrap(HttpMessageProcessor processor)
public HttpBootstrap setPort(int port)
public HttpBootstrap httpHandler(HttpServerHandler httpHandler)
httpHandler - public HttpBootstrap webSocketHandler(WebSocketHandler webSocketHandler)
public HttpServerConfiguration configuration()
public void start()
RuntimeExceptionpublic void shutdown()
Copyright © 2025. All rights reserved.