Class WebSocketGraphQlRequest
java.lang.Object
org.springframework.graphql.support.DefaultGraphQlRequest
org.springframework.graphql.support.DefaultExecutionGraphQlRequest
org.springframework.graphql.server.WebGraphQlRequest
org.springframework.graphql.server.WebSocketGraphQlRequest
- All Implemented Interfaces:
ExecutionGraphQlRequest, GraphQlRequest
WebGraphQlRequest extension for
server handling of GraphQL over WebSocket requests.- Since:
- 1.0.0
- Author:
- Rossen Stoyanchev
-
Field Summary
Fields inherited from class DefaultGraphQlRequest
EXTENSIONS_KEY, OPERATION_NAME_KEY, QUERY_KEY, VARIABLES_KEY -
Constructor Summary
ConstructorsConstructorDescriptionWebSocketGraphQlRequest(URI uri, HttpHeaders headers, @Nullable MultiValueMap<String, HttpCookie> cookies, @Nullable InetSocketAddress remoteAddress, Map<String, Object> attributes, Map<String, Object> body, String id, @Nullable Locale locale, WebSocketSessionInfo sessionInfo) Create an instance.WebSocketGraphQlRequest(URI uri, HttpHeaders headers, @Nullable MultiValueMap<String, HttpCookie> cookies, Map<String, Object> attributes, Map<String, Object> body, String id, @Nullable Locale locale, WebSocketSessionInfo sessionInfo) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionReturn information about the underlying WebSocket session.Methods inherited from class WebGraphQlRequest
getAttributes, getCookies, getHeaders, getRemoteAddress, getUriMethods inherited from class DefaultExecutionGraphQlRequest
configureExecutionInput, executionId, getExecutionId, getId, getLocale, toExecutionInput, toStringMethods inherited from class DefaultGraphQlRequest
equals, getDocument, getExtensions, getOperationName, getVariables, hashCode, toMapMethods inherited from interface GraphQlRequest
getDocument, getExtensions, getOperationName, getVariables, toMap
-
Constructor Details
-
WebSocketGraphQlRequest
public WebSocketGraphQlRequest(URI uri, HttpHeaders headers, @Nullable MultiValueMap<String, HttpCookie> cookies, @Nullable InetSocketAddress remoteAddress, Map<String, Object> attributes, Map<String, Object> body, String id, @Nullable Locale locale, WebSocketSessionInfo sessionInfo) Create an instance.- Parameters:
uri- the URL for the HTTP request or WebSocket handshakeheaders- the HTTP request headerscookies- the HTTP request cookiesremoteAddress- the client remote addressattributes- session attributesbody- the deserialized content of the GraphQL requestid- the id from the GraphQL over WebSocket"subscribe"messagelocale- the locale from the HTTP request, if anysessionInfo- the WebSocket session id- Since:
- 1.3.0
-
WebSocketGraphQlRequest
@Deprecated(since="1.3.0", forRemoval=true) public WebSocketGraphQlRequest(URI uri, HttpHeaders headers, @Nullable MultiValueMap<String, HttpCookie> cookies, Map<String, Object> attributes, Map<String, Object> body, String id, @Nullable Locale locale, WebSocketSessionInfo sessionInfo) Deprecated, for removal: This API element is subject to removal in a future version.Create an instance.- Parameters:
uri- the URL for the HTTP request or WebSocket handshakeheaders- the HTTP request headerscookies- the HTTP request cookiesattributes- session attributesbody- the deserialized content of the GraphQL requestid- the id from the GraphQL over WebSocket"subscribe"messagelocale- the locale from the HTTP request, if anysessionInfo- the WebSocket session id- Since:
- 1.1.3
-
-
Method Details
-
getSessionInfo
Return information about the underlying WebSocket session.
-
WebSocketGraphQlRequest(URI, HttpHeaders, MultiValueMap, InetSocketAddress, Map, Map, String, Locale, WebSocketSessionInfo)