Class: ApolloWSHandler

vertx-web-graphql-js/apollo_ws_handler~ ApolloWSHandler

new ApolloWSHandler()

Source:

Methods

connectionHandler(connectionHandler) → {ApolloWSHandler}

Customize the connection . This handler will be called at the beginning of each websocket connection.
Parameters:
Name Type Description
connectionHandler function
Source:
Returns:
a reference to this, so the API can be used fluently
Type
ApolloWSHandler

endHandler(endHandler) → {ApolloWSHandler}

Customize the end . This handler will be called at the end of each websocket connection.
Parameters:
Name Type Description
endHandler function
Source:
Returns:
a reference to this, so the API can be used fluently
Type
ApolloWSHandler

handle(event)

Something has happened, so handle it.
Parameters:
Name Type Description
event RoutingContext the event to handle
Source:

messageHandler(messageHandler) → {ApolloWSHandler}

Customize the message . This handler will be called for each ApolloWSMessage received.
Parameters:
Name Type Description
messageHandler function
Source:
Returns:
a reference to this, so the API can be used fluently
Type
ApolloWSHandler

queryContext(factory) → {ApolloWSHandler}

Customize the query context object. The provided factory method will be invoked for each incoming GraphQL request.
Parameters:
Name Type Description
factory function
Source:
Returns:
a reference to this, so the API can be used fluently
Type
ApolloWSHandler