Class

Bucket

Bucket

Bucket represents a storage grouping of data within a Couchbase Server cluster.

Members

# name

Returns the name of this bucket.

View Source bucket.js, line 161

Methods

# collection(collectionName) → {Collection}

Gets a reference to a specific collection.

Parameters:
Name Type Description
collectionName string

View Source bucket.js, line 120

Never

Collection

# collections() → {CollectionManager}

Gets a collection manager for this bucket

View Source bucket.js, line 151

Never

# defaultCollection() → {Collection}

Gets a reference to the default collection.

View Source bucket.js, line 131

Never

Collection

# defaultScope() → {Scope}

Gets a reference to the default scope.

View Source bucket.js, line 106

Never

Scope

# scope(scopeName) → {Scope}

Gets a reference to a specific scope.

Parameters:
Name Type Description
scopeName string

View Source bucket.js, line 94

Never

Scope

# viewIndexes() → {ViewIndexManager}

Gets a view index manager for this bucket

View Source bucket.js, line 141

Never

# async viewQuery(designDoc, viewName, options, callbackopt) → {Promise.<ViewQueryResult>}

Parameters:
Name Type Attributes Description
designDoc string

The design document containing the view to query

viewName string

The name of the view to query

options *
include_docs boolean <optional>
stale ViewUpdateMode <optional>
skip integer <optional>
limit integer <optional>
order ViewOrderMode <optional>
reduce string <optional>
group boolean <optional>
group_level integer <optional>
key string <optional>
keys Array.<string> <optional>
range * <optional>
range.start string | Array.<string> <optional>
range.end string | Array.<string> <optional>
range.inclusive_end boolean <optional>
id_range Array.<string> <optional>
id_range.start string <optional>
id_range.end string <optional>
include_docs string <optional>
full_set boolean <optional>
on_error ViewErrorMode <optional>
timeout integer <optional>
callback ViewQueryCallback <optional>

View Source bucket.js, line 80

CouchbaseError

Promise.<ViewQueryResult>