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

Options for collection::scan(). More...

#include <couchbase/scan_options.hxx>

Inheritance diagram for scan_options:
Inheritance graph

Classes

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

Public Member Functions

auto ids_only (bool ids_only) -> scan_options &
 Specifies whether only document IDs should be included in the results.
 
auto consistent_with (const mutation_state &state) -> scan_options &
 Sets the mutation_tokens this scan should be consistent with.
 
auto batch_byte_limit (std::uint32_t batch_byte_limit) -> scan_options &
 Allows to limit the maximum amount of bytes that are sent from the server in each partition batch.
 
auto batch_item_limit (std::uint32_t batch_item_limit) -> scan_options &
 Allows to limit the maximum number of scan items that are sent from the server in each partition batch.
 
auto concurrency (std::uint16_t concurrency) -> scan_options &
 Specifies the maximum number of partitions that can be scanned concurrently.
 
auto build () const -> built
 Validates options and returns them as an immutable value.
 
- Public Member Functions inherited from common_options< scan_options >
auto timeout (const std::chrono::milliseconds timeout) -> scan_options &
 Specifies a custom per-operation timeout.
 
auto retry_strategy (const std::shared_ptr< retry_strategy > strategy) -> scan_options &
 Specifies a custom couchbase::retry_strategy for this operation.
 

Additional Inherited Members

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

Detailed Description

Options for collection::scan().

Since
1.0.0
Committed
Generally available API and should be preferred in production

Member Function Documentation

◆ batch_byte_limit()

auto batch_byte_limit ( std::uint32_t batch_byte_limit) -> scan_options&
inline

Allows to limit the maximum amount of bytes that are sent from the server in each partition batch.

Defaults to 15,000.

Parameters
batch_byte_limitthe byte limit
Returns
the options builder for chaining purposes.
Since
1.0.0
Committed
Generally available API and should be preferred in production

◆ batch_item_limit()

auto batch_item_limit ( std::uint32_t batch_item_limit) -> scan_options&
inline

Allows to limit the maximum number of scan items that are sent from the server in each partition batch.

Defaults to 50.

Parameters
batch_item_limitthe item limit
Returns
the options builder for chaining purposes.
Since
1.0.0
Committed
Generally available API and should be preferred in production

◆ 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

◆ concurrency()

auto concurrency ( std::uint16_t concurrency) -> scan_options&
inline

Specifies the maximum number of partitions that can be scanned concurrently.

Defaults to 1.

Parameters
concurrencythe maximum number of concurrent partition scans
Returns
the options builder for chaining purposes.
Since
1.0.0
Committed
Generally available API and should be preferred in production

◆ consistent_with()

auto consistent_with ( const mutation_state & state) -> scan_options&
inline

Sets the mutation_tokens this scan should be consistent with.

These mutation tokens are returned from mutations (i.e. as part of a mutation_result) and if you want your scan to include those you need to pass the mutation tokens into a mutation_state.

Parameters
statethe mutation state containing the mutation tokens.
Returns
the options builder for chaining purposes.
Since
1.0.0
Committed
Generally available API and should be preferred in production

◆ ids_only()

auto ids_only ( bool ids_only) -> scan_options&
inline

Specifies whether only document IDs should be included in the results.

Defaults to false.

Parameters
ids_onlyif set to true the content will not be included in the results
Returns
the options builder for chaining purposes.
Since
1.0.0
Committed
Generally available API and should be preferred in production

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