io.vertx.rxjava.ext.web.handler.sockjs

## Class SockJSHandler

- java.lang.Object
- - io.vertx.rxjava.ext.web.handler.sockjs.SockJSHandler

- All Implemented Interfaces:
    Handler<RoutingContext>

      public class SockJSHandler
      extends Object
      implements Handler<RoutingContext>

  A handler that allows you to handle SockJS connections from clients.

  We currently support version 0.3.3 of the SockJS protocol, which can be found in this tag:

  NOTE: This class has been automatically generated from the `original` non RX-ified interface using Vert.x codegen.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static TypeArg<SockJSHandler>` | `__TYPE_ARG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `SockJSHandler(SockJSHandler delegate)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `SockJSHandler` | `bridge(BridgeOptions bridgeOptions)` Bridge the SockJS handler to the Vert.x event bus.
    `SockJSHandler` | `bridge(BridgeOptions bridgeOptions, Handler<BridgeEvent> bridgeEventHandler)` Like `bridge(io.vertx.ext.web.handler.sockjs.BridgeOptions)` but specifying a handler that will receive bridge events.
    `static SockJSHandler` | `create(Vertx vertx)` Create a SockJS handler
    `static SockJSHandler` | `create(Vertx vertx, SockJSHandlerOptions options)` Create a SockJS handler
    `SockJSHandler` | `getDelegate()`
    `void` | `handle(RoutingContext arg0)` Something has happened, so handle it.
    `static void` | `installTestApplications(Router router, Vertx vertx)` Install SockJS test applications on a router - used when running the SockJS test suite
    `static SockJSHandler` | `newInstance(SockJSHandler arg)`
    `SockJSHandler` | `socketHandler(Handler<SockJSSocket> handler)` Set a SockJS socket handler.

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

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

- - ### Field Detail

    - #### __TYPE_ARG

          public static final TypeArg<SockJSHandler> __TYPE_ARG

  - ### Constructor Detail

    - #### SockJSHandler

          public SockJSHandler(SockJSHandler delegate)

  - ### Method Detail

    - #### getDelegate

          public SockJSHandler getDelegate()

    - #### handle

          public void handle(RoutingContext arg0)

      Description copied from interface: `Handler`
      Something has happened, so handle it.
      Specified by:
        `handle` in interface `Handler<RoutingContext>`
      Parameters:
        `arg0` - the event to handle

    - #### create

          public static SockJSHandler create(Vertx vertx)

      Create a SockJS handler
      Parameters:
        `vertx` - the Vert.x instance
      Returns:
        the handler

    - #### create

          public static SockJSHandler create(Vertx vertx,
                                             SockJSHandlerOptions options)

      Create a SockJS handler
      Parameters:
        `vertx` - the Vert.x instance
        `options` - options to configure the handler
      Returns:
        the handler

    - #### installTestApplications

          public static void installTestApplications(Router router,
                                                     Vertx vertx)

      Install SockJS test applications on a router - used when running the SockJS test suite
      Parameters:
        `router` - the router to install on
        `vertx` - the Vert.x instance

    - #### socketHandler

          public SockJSHandler socketHandler(Handler<SockJSSocket> handler)

      Set a SockJS socket handler. This handler will be called with a SockJS socket whenever a SockJS connection is made from a client
      Parameters:
        `handler` - the handler
      Returns:
        a reference to this, so the API can be used fluently

    - #### bridge

          public SockJSHandler bridge(BridgeOptions bridgeOptions)

      Bridge the SockJS handler to the Vert.x event bus. This basically installs a built-in SockJS socket handler which takes SockJS traffic and bridges it to the event bus, thus allowing you to extend the server-side Vert.x event bus to browsers
      Parameters:
        `bridgeOptions` - options to configure the bridge with
      Returns:
        a reference to this, so the API can be used fluently

    - #### bridge

          public SockJSHandler bridge(BridgeOptions bridgeOptions,
                                      Handler<BridgeEvent> bridgeEventHandler)

      Like `bridge(io.vertx.ext.web.handler.sockjs.BridgeOptions)` but specifying a handler that will receive bridge events.
      Parameters:
        `bridgeOptions` - options to configure the bridge with
        `bridgeEventHandler` - handler to receive bridge events
      Returns:
        a reference to this, so the API can be used fluently

    - #### newInstance

          public static SockJSHandler newInstance(SockJSHandler arg)

Copyright © 2017. All rights reserved.