Couchbase C++ SDK 1.0.1 (rev. 58d46d7)
Loading...
Searching...
No Matches
create_primary_query_index_options Class Reference

#include <couchbase/create_primary_query_index_options.hxx>

Inheritance diagram for create_primary_query_index_options:
Inheritance graph

Classes

struct  built
 Immutable value object representing consistent options. More...
 

Public Member Functions

auto index_name (std::string index_name) -> create_primary_query_index_options &
 Give the primary index a name.
 
auto ignore_if_exists (bool ignore_if_exists) -> create_primary_query_index_options &
 Set flag to ignore error if the index already exists.
 
auto build_deferred (bool deferred) -> create_primary_query_index_options &
 Set flag to defer building of the index.
 
auto num_replicas (uint8_t num_replicas) -> create_primary_query_index_options &
 Set the number of replicas the index will have.
 
auto build () const -> built
 Validates options and returns them as an immutable value.
 
- Public Member Functions inherited from common_options< create_primary_query_index_options >
auto timeout (const std::chrono::milliseconds timeout) -> create_primary_query_index_options &
 Specifies a custom per-operation timeout.
 
auto retry_strategy (const std::shared_ptr< retry_strategy > strategy) -> create_primary_query_index_options &
 Specifies a custom couchbase::retry_strategy for this operation.
 

Additional Inherited Members

- Protected Member Functions inherited from common_options< create_primary_query_index_options >
auto build_common_options () const -> built
 
auto self () -> create_primary_query_index_options &
 Allows to return the right options builder instance for child implementations.
 

Member Function Documentation

◆ build()

auto build ( ) const -> built
inline

Validates options and returns them as an immutable value.

Returns
consistent options as an immutable value
Exceptions
std::system_errorwith code errc::common::invalid_argument if the options are not valid
Since
1.0.0
Internal
Internal interface

◆ build_deferred()

auto build_deferred ( bool deferred) -> create_primary_query_index_options&
inline

Set flag to defer building of the index.

The default is false, meaning start building the index immediately.

Parameters
deferred
Returns
reference to this object, for use in chaining.
Since
1.0.0
Committed
Generally available API and should be preferred in production

◆ ignore_if_exists()

auto ignore_if_exists ( bool ignore_if_exists) -> create_primary_query_index_options&
inline

Set flag to ignore error if the index already exists.

The default is to not ignore the error.

Parameters
ignore_if_existsif true, we don't return an error if the index already exists
Returns
reference to this object, for use in chaining.
Since
1.0.0
Committed
Generally available API and should be preferred in production

◆ index_name()

auto index_name ( std::string index_name) -> create_primary_query_index_options&
inline

Give the primary index a name.

defaults to #primary

Parameters
index_name
Returns
reference to this object, for use in chaining.

◆ num_replicas()

auto num_replicas ( uint8_t num_replicas) -> create_primary_query_index_options&
inline

Set the number of replicas the index will have.

Parameters
num_replicas
Returns
reference to this object, for use in chaining.
Since
1.0.0
Committed
Generally available API and should be preferred in production

The documentation for this class was generated from the following file: