io.vertx.ext.web.handler.graphql.ws

## Interface GraphQLWSHandlerBuilder

-     public interface GraphQLWSHandlerBuilder

  A builder for `GraphQLWSHandler` instances.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `GraphQLWSHandlerBuilder` | `beforeExecute(Handler<ExecutionInputBuilderWithContext<Message>> beforeExecuteHandler)` Set a callback to invoke before executing a GraphQL query.
    `GraphQLWSHandler` | `build()`
    `GraphQLWSHandlerBuilder` | `onConnectionInit(Handler<ConnectionInitEvent> connectionInitHandler)` Customize the connection init `Handler`.
    `GraphQLWSHandlerBuilder` | `onMessage(Handler<Message> messageHandler)` Customize the message `Handler`.
    `GraphQLWSHandlerBuilder` | `onSocketEnd(Handler<ServerWebSocket> endHandler)` Customize the end `Handler`.
    `GraphQLWSHandlerBuilder` | `with(GraphQLWSOptions options)` Change the `GraphQLWSOptions` to use.

- - ### Method Detail

    - #### with

          GraphQLWSHandlerBuilder with(GraphQLWSOptions options)

      Change the `GraphQLWSOptions` to use.
      Returns:
        a reference to this, so the API can be used fluently

    - #### onConnectionInit

          GraphQLWSHandlerBuilder onConnectionInit(Handler<ConnectionInitEvent> connectionInitHandler)

      Customize the connection init `Handler`. This handler will be called when the `MessageType.CONNECTION_INIT` message is received.
      Returns:
        a reference to this, so the API can be used fluently

    - #### beforeExecute

          GraphQLWSHandlerBuilder beforeExecute(Handler<ExecutionInputBuilderWithContext<Message>> beforeExecuteHandler)

      Set a callback to invoke before executing a GraphQL query.
      Parameters:
        `beforeExecuteHandler` - the callback to invoke
      Returns:
        a reference to this, so the API can be used fluently

    - #### onMessage

          GraphQLWSHandlerBuilder onMessage(Handler<Message> messageHandler)

      Customize the message `Handler`. This handler will be called for each `Message` received.
      Returns:
        a reference to this, so the API can be used fluently

    - #### onSocketEnd

          GraphQLWSHandlerBuilder onSocketEnd(Handler<ServerWebSocket> endHandler)

      Customize the end `Handler`. This handler will be called at the end of each websocket connection.
      Returns:
        a reference to this, so the API can be used fluently

    - #### build

          GraphQLWSHandler build()

      Returns:
        a new instance of `GraphQLWSHandler`

Copyright © 2025 Eclipse. All rights reserved.