org.apache.tinkerpop.gremlin.driver

## Class Channelizer.WebSocketChannelizer

- java.lang.Object
- - <any>
  - - org.apache.tinkerpop.gremlin.driver.Channelizer.AbstractChannelizer
    - - org.apache.tinkerpop.gremlin.driver.Channelizer.WebSocketChannelizer

- All Implemented Interfaces:
    Channelizer
  Enclosing interface:
    Channelizer

      public static final class Channelizer.WebSocketChannelizer
      extends Channelizer.AbstractChannelizer

  WebSocket `Channelizer` implementation.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface org.apache.tinkerpop.gremlin.driver.Channelizer

      `Channelizer.AbstractChannelizer, Channelizer.NioChannelizer, Channelizer.WebSocketChannelizer`

  - ### Field Summary

    - ### Fields inherited from class org.apache.tinkerpop.gremlin.driver.Channelizer.AbstractChannelizer

      `cluster, connection, PIPELINE_GREMLIN_HANDLER, PIPELINE_GREMLIN_SASL_HANDLER`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `WebSocketChannelizer()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close(Channel channel)` Sends a `CloseWebSocketFrame` to the server for the specified channel.
    `void` | `configure(ChannelPipeline pipeline)`
    `void` | `connected()` Called after the channel connects.
    `Object` | `createKeepAliveMessage()` Create a message for the driver to use as a "keep-alive" for the connection.
    `void` | `init(org.apache.tinkerpop.gremlin.driver.Connection connection)` Initializes the `Channelizer`.
    `boolean` | `supportsKeepAlive()` Keep-alive is supported through the ping/pong websocket protocol.
    `boolean` | `supportsSsl()`

    - ### Methods inherited from class org.apache.tinkerpop.gremlin.driver.Channelizer.AbstractChannelizer

      `finalize, initChannel`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### WebSocketChannelizer

          public WebSocketChannelizer()

  - ### Method Detail

    - #### init

          public void init(org.apache.tinkerpop.gremlin.driver.Connection connection)

      Description copied from interface: `Channelizer`
      Initializes the `Channelizer`. Called just after construction.
      Specified by:
        `init` in interface `Channelizer`
      Overrides:
        `init` in class `Channelizer.AbstractChannelizer`

    - #### supportsKeepAlive

          public boolean supportsKeepAlive()

      Keep-alive is supported through the ping/pong websocket protocol.
      See Also:
        IETF RFC 6455

    - #### createKeepAliveMessage

          public Object createKeepAliveMessage()

      Description copied from interface: `Channelizer`
      Create a message for the driver to use as a "keep-alive" for the connection. This method will only be used if `Channelizer.supportsKeepAlive()` is `true`.

    - #### close

          public void close(Channel channel)

      Sends a `CloseWebSocketFrame` to the server for the specified channel.
      Specified by:
        `close` in interface `Channelizer`
      Overrides:
        `close` in class `Channelizer.AbstractChannelizer`

    - #### supportsSsl

          public boolean supportsSsl()

      Overrides:
        `supportsSsl` in class `Channelizer.AbstractChannelizer`

    - #### configure

          public void configure(ChannelPipeline pipeline)

      Specified by:
        `configure` in class `Channelizer.AbstractChannelizer`

    - #### connected

          public void connected()

      Description copied from interface: `Channelizer`
      Called after the channel connects. The `Channelizer` may need to perform some functions, such as a handshake.

Copyright © 2013–2018 Apache Software Foundation. All rights reserved.