io.vertx.rxjava.config

## Class ConfigRetriever

- java.lang.Object
- - io.vertx.rxjava.config.ConfigRetriever

-     public class ConfigRetriever
      extends Object

  Defines a configuration retriever that read configuration from and tracks changes periodically.

  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<ConfigRetriever>` | `__TYPE_ARG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ConfigRetriever(ConfigRetriever delegate)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `close()` Closes the retriever.
    `ReadStream<JsonObject>` | `configStream()`
    `static ConfigRetriever` | `create(Vertx vertx)` Creates an instance of the default implementation of the `ConfigRetriever`, using the default settings (json file, system properties and environment variables).
    `static ConfigRetriever` | `create(Vertx vertx, ConfigRetrieverOptions options)` Creates an instance of the default implementation of the `ConfigRetriever`.
    `JsonObject` | `getCachedConfig()` Gets the last computed configuration.
    `void` | `getConfig(Handler<AsyncResult<JsonObject>> completionHandler)` Reads the configuration from the different and computes the final configuration.
    `static Future<JsonObject>` | `getConfigAsFuture(ConfigRetriever retriever)` Same as `getConfig(io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>)`, but returning a object.
    `ConfigRetriever` | `getDelegate()`
    `void` | `listen(Handler<ConfigChange> listener)` Registers a listener receiving configuration changes.
    `static ConfigRetriever` | `newInstance(ConfigRetriever arg)`
    `rx.Single<JsonObject>` | `rxGetConfig()` Reads the configuration from the different and computes the final configuration.

    - ### 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<ConfigRetriever> __TYPE_ARG

  - ### Constructor Detail

    - #### ConfigRetriever

          public ConfigRetriever(ConfigRetriever delegate)

  - ### Method Detail

    - #### getDelegate

          public ConfigRetriever getDelegate()

    - #### create

          public static ConfigRetriever create(Vertx vertx,
                                               ConfigRetrieverOptions options)

      Creates an instance of the default implementation of the `ConfigRetriever`.
      Parameters:
        `vertx` - the vert.x instance
        `options` - the options, must not be `null`, must contain the list of configured store.
      Returns:
        the created instance.

    - #### create

          public static ConfigRetriever create(Vertx vertx)

      Creates an instance of the default implementation of the `ConfigRetriever`, using the default settings (json file, system properties and environment variables).
      Parameters:
        `vertx` - the vert.x instance
      Returns:
        the created instance.

    - #### getConfigAsFuture

          public static Future<JsonObject> getConfigAsFuture(ConfigRetriever retriever)

      Same as `getConfig(io.vertx.core.Handler<io.vertx.core.AsyncResult<io.vertx.core.json.JsonObject>>)`, but returning a object. The result is a .
      Parameters:
        `retriever` - the config retrieve
      Returns:
        the future completed when the configuration is retrieved

    - #### getConfig

          public void getConfig(Handler<AsyncResult<JsonObject>> completionHandler)

      Reads the configuration from the different and computes the final configuration.
      Parameters:
        `completionHandler` - handler receiving the computed configuration, or a failure if the configuration cannot be retrieved

    - #### rxGetConfig

          public rx.Single<JsonObject> rxGetConfig()

      Reads the configuration from the different and computes the final configuration.
      Returns:

    - #### close

          public void close()

      Closes the retriever.

    - #### getCachedConfig

          public JsonObject getCachedConfig()

      Gets the last computed configuration.
      Returns:
        the last configuration

    - #### listen

          public void listen(Handler<ConfigChange> listener)

      Registers a listener receiving configuration changes. This method cannot only be called if the configuration is broadcasted.
      Parameters:
        `listener` - the listener

    - #### configStream

          public ReadStream<JsonObject> configStream()

      Returns:
        the stream of configurations. It's single stream (unicast) and that delivers the last known config and the successors periodically.

    - #### newInstance

          public static ConfigRetriever newInstance(ConfigRetriever arg)

Copyright © 2017. All rights reserved.