Package org.springframework.graphql
Interface GraphQlRequest
- All Known Subinterfaces:
ClientGraphQlRequest
,ExecutionGraphQlRequest
- All Known Implementing Classes:
DefaultExecutionGraphQlRequest
,DefaultGraphQlRequest
,RSocketGraphQlRequest
,SerializableGraphQlRequest
,WebGraphQlRequest
,WebSocketGraphQlRequest
public interface GraphQlRequest
Represents a GraphQL request with the inputs to pass to a GraphQL service
including a
document
, operationName
, and variables
.
The request can be turned to a Map via toMap()
and to be
submitted as JSON over HTTP or WebSocket.
- Since:
- 1.0.0
- Author:
- Rossen Stoyanchev
-
Method Summary
Modifier and TypeMethodDescriptionReturn the GraphQL document which is the textual representation of an operation (or operations) to perform, including any selection sets and fragments.Return implementor specific, protocol extensions, if any.Return the name of the operation in thedocument
to execute, if the document contains multiple operations.Return values for variable defined by the operation.toMap()
-
Method Details
-
getDocument
String getDocument()Return the GraphQL document which is the textual representation of an operation (or operations) to perform, including any selection sets and fragments. -
getOperationName
Return the name of the operation in thedocument
to execute, if the document contains multiple operations. -
getVariables
Return values for variable defined by the operation. -
getExtensions
Return implementor specific, protocol extensions, if any. -
toMap
Convert the request to aMap
as defined in GraphQL over HTTP and GraphQL over WebSocket.Key Value query document
operationName operationName
variables variables
-