interface QueryHandlerInterface (View source)

Query handlers are responsible for applying a query as a string to a Schema object and returning a result.

Methods

array
query(Schema $schema, string|DocumentNode $query, array $params = [])

No description

array
serialiseResult(ExecutionResult $executionResult)

Serialise a Graphql result object for output

Details

array query(Schema $schema, string|DocumentNode $query, array $params = [])

Parameters

Schema $schema
string|DocumentNode $query
array $params

Return Value

array

array serialiseResult(ExecutionResult $executionResult)

Serialise a Graphql result object for output

Parameters

ExecutionResult $executionResult

Return Value

array

QueryHandlerInterface addContextProvider(ContextProvider $provider)

Parameters

ContextProvider $provider

Return Value

QueryHandlerInterface