io.vertx.reactivex.ext.stomp

## Class StompClient

- java.lang.Object
- - io.vertx.reactivex.ext.stomp.StompClient

-     public class StompClient
      extends Object

  Defines a STOMP client.

  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 io.vertx.lang.rx.TypeArg<StompClient>` | `__TYPE_ARG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `StompClient(Object delegate)`
    `StompClient(StompClient delegate)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()` Closes the client.
    `StompClient` | `connect(Handler<AsyncResult<StompClientConnection>> resultHandler)` Connects to the server using the host and port configured in the client's options.
    `StompClient` | `connect(int port, String host, Handler<AsyncResult<StompClientConnection>> resultHandler)` Connects to the server.
    `StompClient` | `connect(int port, String host, NetClient net, Handler<AsyncResult<StompClientConnection>> resultHandler)` Connects to the server.
    `StompClient` | `connect(NetClient net, Handler<AsyncResult<StompClientConnection>> resultHandler)` Connects to the server.
    `static StompClient` | `create(Vertx vertx)` Creates a `StompClient` using the default implementation.
    `static StompClient` | `create(Vertx vertx, StompClientOptions options)` Creates a `StompClient` using the default implementation.
    `boolean` | `equals(Object o)`
    `StompClient` | `errorFrameHandler(Handler<Frame> handler)` A general error frame handler.
    `StompClient` | `exceptionHandler(Handler<Throwable> handler)` Sets an exception handler notified for TCP-level errors.
    `StompClient` | `getDelegate()`
    `int` | `hashCode()`
    `boolean` | `isClosed()`
    `static StompClient` | `newInstance(StompClient arg)`
    `StompClientOptions` | `options()`
    `StompClient` | `receivedFrameHandler(Handler<Frame> handler)` Configures a received handler that gets notified when a STOMP frame is received by the client.
    `Single<StompClientConnection>` | `rxConnect()` Connects to the server using the host and port configured in the client's options.
    `Single<StompClientConnection>` | `rxConnect(int port, String host)` Connects to the server.
    `Single<StompClientConnection>` | `rxConnect(int port, String host, NetClient net)` Connects to the server.
    `Single<StompClientConnection>` | `rxConnect(NetClient net)` Connects to the server.
    `String` | `toString()`
    `Vertx` | `vertx()`
    `StompClient` | `writingFrameHandler(Handler<Frame> handler)` Configures a writing handler that gets notified when a STOMP frame is written on the wire.

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

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### __TYPE_ARG

          public static final io.vertx.lang.rx.TypeArg<StompClient> __TYPE_ARG

  - ### Constructor Detail

    - #### StompClient

          public StompClient(StompClient delegate)

    - #### StompClient

          public StompClient(Object delegate)

  - ### Method Detail

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### getDelegate

          public StompClient getDelegate()

    - #### create

          public static StompClient create(Vertx vertx)

      Creates a `StompClient` using the default implementation.
      Parameters:
        `vertx` - the vert.x instance to use
      Returns:
        the created `StompClient`

    - #### create

          public static StompClient create(Vertx vertx,
                                           StompClientOptions options)

      Creates a `StompClient` using the default implementation.
      Parameters:
        `vertx` - the vert.x instance to use
        `options` - the options
      Returns:
        the created `StompClient`

    - #### connect

          public StompClient connect(int port,
                                     String host,
                                     Handler<AsyncResult<StompClientConnection>> resultHandler)

      Connects to the server.
      Parameters:
        `port` - the server port
        `host` - the server host
        `resultHandler` - handler called with the connection result
      Returns:
        the current `StompClient`

    - #### rxConnect

          public Single<StompClientConnection> rxConnect(int port,
                                                         String host)

      Connects to the server.
      Parameters:
        `port` - the server port
        `host` - the server host
      Returns:
        the current `StompClient`

    - #### connect

          public StompClient connect(NetClient net,
                                     Handler<AsyncResult<StompClientConnection>> resultHandler)

      Connects to the server.
      Parameters:
        `net` - the NET client to use
        `resultHandler` - handler called with the connection result
      Returns:
        the current `StompClient`

    - #### rxConnect

          public Single<StompClientConnection> rxConnect(NetClient net)

      Connects to the server.
      Parameters:
        `net` - the NET client to use
      Returns:
        the current `StompClient`

    - #### connect

          public StompClient connect(int port,
                                     String host,
                                     NetClient net,
                                     Handler<AsyncResult<StompClientConnection>> resultHandler)

      Connects to the server.
      Parameters:
        `port` - the server port
        `host` - the server host
        `net` - the NET client to use
        `resultHandler` - handler called with the connection result
      Returns:
        the current `StompClient`

    - #### rxConnect

          public Single<StompClientConnection> rxConnect(int port,
                                                         String host,
                                                         NetClient net)

      Connects to the server.
      Parameters:
        `port` - the server port
        `host` - the server host
        `net` - the NET client to use
      Returns:
        the current `StompClient`

    - #### connect

          public StompClient connect(Handler<AsyncResult<StompClientConnection>> resultHandler)

      Connects to the server using the host and port configured in the client's options.
      Parameters:
        `resultHandler` - handler called with the connection result. A failure will be sent to the handler if a TCP level issue happen before the `CONNECTED` frame is received. Afterwards, the `exceptionHandler(io.vertx.core.Handler<java.lang.Throwable>)` is called.
      Returns:
        the current `StompClient`

    - #### rxConnect

          public Single<StompClientConnection> rxConnect()

      Connects to the server using the host and port configured in the client's options.
      Returns:
        the current `StompClient`

    - #### receivedFrameHandler

          public StompClient receivedFrameHandler(Handler<Frame> handler)

      Configures a received handler that gets notified when a STOMP frame is received by the client. This handler can be used for logging, debugging or ad-hoc behavior. The frame can still be modified at the time.

      When a connection is created, the handler is used as `StompClientConnection.receivedFrameHandler(io.vertx.core.Handler<io.vertx.ext.stomp.Frame>)`.

      Parameters:
        `handler` - the handler
      Returns:
        the current `StompClient`

    - #### writingFrameHandler

          public StompClient writingFrameHandler(Handler<Frame> handler)

      Configures a writing handler that gets notified when a STOMP frame is written on the wire. This handler can be used for logging, debugging or ad-hoc behavior. The frame can still be modified at the time.

      When a connection is created, the handler is used as `StompClientConnection.writingFrameHandler(io.vertx.core.Handler<io.vertx.ext.stomp.Frame>)`.

      Parameters:
        `handler` - the handler
      Returns:
        the current `StompClient`

    - #### errorFrameHandler

          public StompClient errorFrameHandler(Handler<Frame> handler)

      A general error frame handler. It can be used to catch `ERROR` frame emitted during the connection process (wrong authentication). This error handler will be pass to all `StompClientConnection` created from this client. Obviously, the client can override it when the connection is established.
      Parameters:
        `handler` - the handler
      Returns:
        the current `StompClient`

    - #### exceptionHandler

          public StompClient exceptionHandler(Handler<Throwable> handler)

      Sets an exception handler notified for TCP-level errors.
      Parameters:
        `handler` - the handler
      Returns:
        the current `StompClient`

    - #### close

          public void close()

      Closes the client.

    - #### options

          public StompClientOptions options()

      Returns:
        the client's options.

    - #### vertx

          public Vertx vertx()

      Returns:
        the vert.x instance used by the client.

    - #### isClosed

          public boolean isClosed()

      Returns:
        whether or not the client is connected to the server.

    - #### newInstance

          public static StompClient newInstance(StompClient arg)

Copyright © 2020 Eclipse. All rights reserved.