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 org.springframework.graphql.support.DefaultGraphQlRequest
EXTENSIONS_KEY, OPERATION_NAME_KEY, QUERY_KEY, VARIABLES_KEY -
Constructor Summary
ConstructorsConstructorDescriptionWebSocketGraphQlRequest(URI uri, HttpHeaders headers, Map<String, Object> body, String id, Locale locale, WebSocketSessionInfo sessionInfo) Deprecated, for removal: This API element is subject to removal in a future version.as of 1.1.3 in favor of the constructor with cookiesWebSocketGraphQlRequest(URI uri, HttpHeaders headers, MultiValueMap<String, HttpCookie> cookies, Map<String, Object> attributes, Map<String, Object> body, String id, Locale locale, WebSocketSessionInfo sessionInfo) Create an instance. -
Method Summary
Modifier and TypeMethodDescriptionReturn information about the underlying WebSocket session.Methods inherited from class org.springframework.graphql.server.WebGraphQlRequest
getAttributes, getCookies, getHeaders, getUriMethods inherited from class org.springframework.graphql.support.DefaultExecutionGraphQlRequest
configureExecutionInput, executionId, getExecutionId, getId, getLocale, toExecutionInput, toStringMethods inherited from class org.springframework.graphql.support.DefaultGraphQlRequest
equals, getDocument, getExtensions, getOperationName, getVariables, hashCode, toMapMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.springframework.graphql.ExecutionGraphQlRequest
configureExecutionInput, executionId, getExecutionId, getId, getLocale, toExecutionInputMethods inherited from interface org.springframework.graphql.GraphQlRequest
getDocument, getExtensions, getOperationName, getVariables, toMap
-
Constructor Details
-
WebSocketGraphQlRequest
@Deprecated(since="1.1.3", forRemoval=true) public WebSocketGraphQlRequest(URI uri, HttpHeaders headers, 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.as of 1.1.3 in favor of the constructor with cookiesCreate an instance.- Parameters:
uri- the URL for the HTTP request or WebSocket handshakeheaders- the HTTP request headersbody- 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
-
WebSocketGraphQlRequest
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) 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.
-