Class DefaultAsyncViewRow

java.lang.Object
com.couchbase.client.java.view.DefaultAsyncViewRow
All Implemented Interfaces:
AsyncViewRow

public class DefaultAsyncViewRow
extends Object
implements AsyncViewRow
Default implementation of a AsyncViewRow.
Since:
2.0
Author:
Michael Nitschinger
  • Constructor Details

  • Method Details

    • id

      public String id()
      Description copied from interface: AsyncViewRow
      The id of the document, if not reduced.
      Specified by:
      id in interface AsyncViewRow
      Returns:
      the id of the document.
    • key

      public Object key()
      Description copied from interface: AsyncViewRow
      The key of the row index. The object can be any valid JSON object, including JsonArray or JsonObject.
      Specified by:
      key in interface AsyncViewRow
      Returns:
      the key.
    • value

      public Object value()
      Description copied from interface: AsyncViewRow
      The value of the row index. The object can be any valid JSON object, including JsonArray or JsonObject.
      Specified by:
      value in interface AsyncViewRow
      Returns:
      the value.
    • document

      public rx.Observable<JsonDocument> document()
      Description copied from interface: AsyncViewRow
      Load the underlying document, if not reduced. The Observable can error under the following conditions: - BackpressureException: If the incoming request rate is too high to be processed. - IllegalStateException: If the view is reduced and the ID is null. - TranscodingException: If the response document could not be decoded.
      Specified by:
      document in interface AsyncViewRow
      Returns:
      a Observable containing the document once loaded.
    • document

      public <D extends Document<?>> rx.Observable<D> document​(Class<D> target)
      Description copied from interface: AsyncViewRow
      Load the underlying document, if not reduced. The Observable can error under the following conditions: - BackpressureException: If the incoming request rate is too high to be processed. - IllegalStateException: If the view is reduced and the ID is null. - TranscodingException: If the response document could not be decoded.
      Specified by:
      document in interface AsyncViewRow
      Parameters:
      target - the target class to decode into.
      Returns:
      a Observable containing the document once loaded.
    • toString

      public String toString()
      Overrides:
      toString in class Object