public class ViewIndexManager extends Object
Constructor and Description |
---|
ViewIndexManager(AsyncViewIndexManager async) |
Modifier and Type | Method and Description |
---|---|
AsyncViewIndexManager |
async() |
void |
dropDesignDocument(String name,
DesignDocumentNamespace namespace)
Removes a design document from the server.
|
void |
dropDesignDocument(String name,
DesignDocumentNamespace namespace,
DropDesignDocumentOptions options)
Removes a design document from the server.
|
List<DesignDocument> |
getAllDesignDocuments(DesignDocumentNamespace namespace)
Returns all of the design documents in the specified namespace.
|
List<DesignDocument> |
getAllDesignDocuments(DesignDocumentNamespace namespace,
GetAllDesignDocumentsOptions options)
Returns all of the design documents in the specified namespace.
|
DesignDocument |
getDesignDocument(String name,
DesignDocumentNamespace namespace)
Returns the design document from the cluster if present.
|
DesignDocument |
getDesignDocument(String name,
DesignDocumentNamespace namespace,
GetDesignDocumentOptions options)
Returns the design document from the cluster if present with custom options.
|
void |
publishDesignDocument(String name)
Convenience method that gets a the document from the development namespace
and upserts it to the production namespace.
|
void |
publishDesignDocument(String name,
PublishDesignDocumentOptions options)
Convenience method that gets a the document from the development namespace
and upserts it to the production namespace.
|
void |
upsertDesignDocument(DesignDocument designDocument,
DesignDocumentNamespace namespace)
Stores the design document on the server under the specified namespace, replacing any existing document
with the same name.
|
void |
upsertDesignDocument(DesignDocument designDocument,
DesignDocumentNamespace namespace,
UpsertDesignDocumentOptions options)
Stores the design document on the server under the specified namespace, replacing any existing document
with the same name.
|
public ViewIndexManager(AsyncViewIndexManager async)
public AsyncViewIndexManager async()
public DesignDocument getDesignDocument(String name, DesignDocumentNamespace namespace)
name
- name of the design document to retrieve.namespace
- namespace to look in.com.couchbase.client.core.error.DesignDocumentNotFoundException
- if there is no design document with the given name present.com.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public DesignDocument getDesignDocument(String name, DesignDocumentNamespace namespace, GetDesignDocumentOptions options)
name
- name of the design document to retrievenamespace
- namespace to look inoptions
- additional optional arguments (timeout, retry, etc.)com.couchbase.client.core.error.DesignDocumentNotFoundException
- if there is no design document with the given name present.com.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public void upsertDesignDocument(DesignDocument designDocument, DesignDocumentNamespace namespace)
designDocument
- document to storenamespace
- namespace to store it incom.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public void upsertDesignDocument(DesignDocument designDocument, DesignDocumentNamespace namespace, UpsertDesignDocumentOptions options)
designDocument
- document to storenamespace
- namespace to store it inoptions
- additional optional arguments (timeout, retry, etc.)com.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public void publishDesignDocument(String name)
name
- name of the development design documentcom.couchbase.client.core.error.DesignDocumentNotFoundException
- if the development namespace does not contain a document with the given namecom.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public void publishDesignDocument(String name, PublishDesignDocumentOptions options)
name
- name of the development design documentoptions
- additional optional arguments (timeout, retry, etc.)com.couchbase.client.core.error.DesignDocumentNotFoundException
- if the development namespace does not contain a document with the given namecom.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public void dropDesignDocument(String name, DesignDocumentNamespace namespace)
name
- name of the document to removenamespace
- namespace to remove it fromcom.couchbase.client.core.error.DesignDocumentNotFoundException
- if the namespace does not contain a document with the given namecom.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public void dropDesignDocument(String name, DesignDocumentNamespace namespace, DropDesignDocumentOptions options)
name
- name of the document to removenamespace
- namespace to remove it fromoptions
- additional optional arguments (timeout, retry, etc.)com.couchbase.client.core.error.DesignDocumentNotFoundException
- if the namespace does not contain a document with the given namecom.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public List<DesignDocument> getAllDesignDocuments(DesignDocumentNamespace namespace)
namespace
- namespace to querycom.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).public List<DesignDocument> getAllDesignDocuments(DesignDocumentNamespace namespace, GetAllDesignDocumentsOptions options)
namespace
- namespace to queryoptions
- additional optional arguments (timeout, retry, etc.)com.couchbase.client.core.error.TimeoutException
- if the operation times out before getting a result.com.couchbase.client.core.error.CouchbaseException
- for all other error reasons (acts as a base type and catch-all).Copyright © 2024 Couchbase, Inc.. All rights reserved.