Packages

abstract class CouchbaseSession extends AnyRef

Java API: A Couchbase session allowing querying and interacting with a specific couchbase bucket.

Not for user extension.

Annotations
@DoNotInherit()
Source
CouchbaseSession.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CouchbaseSession
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new CouchbaseSession()

Abstract Value Members

  1. abstract def asScala: scaladsl.CouchbaseSession
  2. abstract def close(): CompletionStage[Done]

    Close the session and release all resources it holds.

    Close the session and release all resources it holds. Subsequent calls to other methods will likely fail.

  3. abstract def counter(id: String, delta: Long, initial: Long, writeSettings: CouchbaseWriteSettings): CompletionStage[Long]

    Create or increment a counter

    Create or increment a counter

    id

    What counter document id

    delta

    Value to increase the counter with if it does exist

    initial

    Value to start from if the counter does not exist

    returns

    The value of the counter after applying the delta

  4. abstract def counter(id: String, delta: Long, initial: Long): CompletionStage[Long]

    Create or increment a counter

    Create or increment a counter

    id

    What counter document id

    delta

    Value to increase the counter with if it does exist

    initial

    Value to start from if the counter does not exist

    returns

    The value of the counter after applying the delta

  5. abstract def createIndex(indexName: String, ignoreIfExist: Boolean, fields: AnyRef*): CompletionStage[Boolean]

    Create a secondary index for the current bucket.

    Create a secondary index for the current bucket.

    indexName

    the name of the index.

    ignoreIfExist

    if a secondary index already exists with that name, an exception will be thrown unless this is set to true.

    fields

    the JSON fields to index - each can be either String or com.couchbase.client.java.query.dsl.Expression

    returns

    a java.util.concurrent.CompletionStage of true if the index was/will be effectively created, false if the index existed and ignoreIfExist is true. Completion of the CompletionStage does not guarantee the index is online and ready to be used.

  6. abstract def get[T <: Document[_]](id: String, timeout: Duration, documentClass: Class[T]): CompletionStage[Optional[T]]

    timeout

    fail the returned CompletionStage with a TimeoutException if it takes longer than this

    returns

    A document if found or none if there is no document for the id

  7. abstract def get(id: String, timeout: Duration): CompletionStage[Optional[JsonDocument]]

    timeout

    fail the returned CompletionStage with a TimeoutException if it takes longer than this

    returns

    A document if found or none if there is no document for the id

  8. abstract def get[T <: Document[_]](id: String, documentClass: Class[T]): CompletionStage[Optional[T]]

    returns

    A document if found or none if there is no document for the id

  9. abstract def get(id: String): CompletionStage[Optional[JsonDocument]]

    returns

    A document if found or none if there is no document for the id

  10. abstract def insert(document: JsonDocument, writeSettings: CouchbaseWriteSettings): CompletionStage[JsonDocument]

    Insert a JSON document using the given write settings.

    Insert a JSON document using the given write settings.

    For inserting other types of documents see insertDoc.

  11. abstract def insert(document: JsonDocument): CompletionStage[JsonDocument]

    Insert a JSON document using the default write settings.

    Insert a JSON document using the default write settings.

    For inserting other types of documents see insertDoc.

    returns

    A CompletionStage that completes with the written document when the write completes

  12. abstract def insertDoc[T <: Document[_]](document: T, writeSettings: CouchbaseWriteSettings): CompletionStage[T]

    Insert a document using the given write settings.

    Insert a document using the given write settings. Separate from insert to make the most common case smoother with the type inference

  13. abstract def insertDoc[T <: Document[_]](document: T): CompletionStage[T]

    Insert a document using the default write settings.

    Insert a document using the default write settings. Separate from insert to make the most common case smoother with the type inference

    returns

    A CompletionStage that completes with the written document when the write completes

  14. abstract def listIndexes(): Source[IndexInfo, NotUsed]

    List the existing secondary indexes for the bucket

  15. abstract def remove(id: String, writeSettings: CouchbaseWriteSettings): CompletionStage[Done]

    Remove a document by id using the default write settings.

    Remove a document by id using the default write settings.

    returns

    CompletionStage that completes when the document has been removed, if there is no such document the CompletionStage is failed with a DocumentDoesNotExistException

  16. abstract def remove(id: String): CompletionStage[Done]

    Remove a document by id using the default write settings.

    Remove a document by id using the default write settings.

    returns

    CompletionStage that completes when the document has been removed, if there is no such document the CompletionStage is failed with a DocumentDoesNotExistException

  17. abstract def singleResponseQuery(query: N1qlQuery): CompletionStage[Optional[JsonObject]]
  18. abstract def singleResponseQuery(query: Statement): CompletionStage[Optional[JsonObject]]
  19. abstract def streamedQuery(query: Statement): Source[JsonObject, NotUsed]
  20. abstract def streamedQuery(query: N1qlQuery): Source[JsonObject, NotUsed]
  21. abstract def underlying: AsyncBucket
  22. abstract def upsert(document: JsonDocument, writeSettings: CouchbaseWriteSettings): CompletionStage[JsonDocument]

    Upsert using the given write settings.

    Upsert using the given write settings.

    For inserting other types of documents see upsertDoc.

    returns

    a CompletionStage that completes when the upsert is done

  23. abstract def upsert(document: JsonDocument): CompletionStage[JsonDocument]

    Upsert using the default write settings

    Upsert using the default write settings

    For inserting other types of documents see upsertDoc.

    returns

    a CompletionStage that completes when the upsert is done

  24. abstract def upsertDoc[T <: Document[_]](document: T, writeSettings: CouchbaseWriteSettings): CompletionStage[T]

    Upsert using the given write settings.

    Upsert using the given write settings.

    Separate from upsert to make the most common case smoother with the type inference

    returns

    a CompletionStage that completes when the upsert is done

  25. abstract def upsertDoc[T <: Document[_]](document: T): CompletionStage[T]

    Upsert using the default write settings.

    Upsert using the default write settings. Separate from upsert to make the most common case smoother with the type inference

    returns

    a CompletionStage that completes when the upsert is done

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @native() @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  9. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  10. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  11. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  12. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  13. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  14. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  15. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  16. def toString(): String
    Definition Classes
    AnyRef → Any
  17. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  18. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  19. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped