public abstract class AbstractHttpReceivingTransportHandler extends AbstractTransportHandler
logger, UTF8_CHARSET
Constructor and Description |
---|
AbstractHttpReceivingTransportHandler() |
Modifier and Type | Method and Description |
---|---|
protected abstract HttpStatus |
getResponseStatus() |
private void |
handleReadError(ServerHttpResponse resp,
java.lang.String error,
java.lang.String sessionId) |
void |
handleRequest(ServerHttpRequest request,
ServerHttpResponse response,
WebSocketHandler wsHandler,
SockJsSession wsSession)
Handle the given request and delegate messages to the provided
WebSocketHandler . |
protected void |
handleRequestInternal(ServerHttpRequest request,
ServerHttpResponse response,
WebSocketHandler wsHandler,
AbstractHttpSockJsSession sockJsSession) |
protected abstract java.lang.String[] |
readMessages(ServerHttpRequest request) |
getServiceConfig, initialize
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getTransportType
public AbstractHttpReceivingTransportHandler()
public final void handleRequest(ServerHttpRequest request, ServerHttpResponse response, WebSocketHandler wsHandler, SockJsSession wsSession) throws SockJsException
TransportHandler
WebSocketHandler
.request
- the current requestresponse
- the current responsewsHandler
- the target WebSocketHandler (never null
)wsSession
- the SockJS session (never null
)SockJsException
- raised when request processing fails as
explained in SockJsService
protected void handleRequestInternal(ServerHttpRequest request, ServerHttpResponse response, WebSocketHandler wsHandler, AbstractHttpSockJsSession sockJsSession) throws SockJsException
SockJsException
private void handleReadError(ServerHttpResponse resp, java.lang.String error, java.lang.String sessionId)
protected abstract java.lang.String[] readMessages(ServerHttpRequest request) throws java.io.IOException
java.io.IOException
protected abstract HttpStatus getResponseStatus()