Loading...
Searching...
No Matches
mongocxx::v1::change_stream::options Class Reference

`#include <mongocxx/v1/change_stream.hpp>`

## Description

Options for mongocxx::v1::change_stream.

Supported fields include:

- batch_size ("batchSize")
- collation
- comment
- full_document ("fullDocument")
- full_document_before_change ("fullDocumentBeforeChange")
- max_await_time ("maxAwaitTimeMS")
- resume_after ("resumeAfter")
- start_after ("startAfter")
- start_at_operation_time ("startAtOperationTime")

## Public Member Functions

| options ()
| Default initialization.
| options (options &&other) noexcept
| Move constructor.
| options (options const &other)
| Copy construction.
| ~options ()
| Destroy this object.
bsoncxx::v1::stdx::optional< std::int32_t > | batch_size () const
| Return the current "batchSize" option.
options & | batch_size (std::int32_t v)
| Set the "batchSize" option.
bsoncxx::v1::stdx::optional< bsoncxx::v1::document::view > | collation () const
| Return the current "collation" option.
options & | collation (bsoncxx::v1::document::value v)
| Set the "collation" option.
bsoncxx::v1::stdx::optional< bsoncxx::v1::types::view > | comment () const
| Return the current "comment" option.
options & | comment (bsoncxx::v1::types::value v)
| Set the "comment" option.
bsoncxx::v1::stdx::optional< bsoncxx::v1::stdx::string_view > | full_document () const
| Return the current "fullDocument" option.
options & | full_document (std::string v)
| Set the "fullDocument" option.
bsoncxx::v1::stdx::optional< bsoncxx::v1::stdx::string_view > | full_document_before_change () const
| Return the current "fullDocumentBeforeChange" option.
options & | full_document_before_change (std::string v)
| Set the "fullDocumentBeforeChange" option.
bsoncxx::v1::stdx::optional< std::chrono::milliseconds > | max_await_time () const
| Return the current "maxAwaitTimeMS" option.
options & | max_await_time (std::chrono::milliseconds v)
| Set the "maxAwaitTimeMS" option.
options & | operator= (options &&other) noexcept
| Move assignment.
options & | operator= (options const &other)
| Copy assignment.
bsoncxx::v1::stdx::optional< bsoncxx::v1::document::view > | resume_after () const
| Return the current "resumeAfter" option.
options & | resume_after (bsoncxx::v1::document::value v)
| Set the "resumeAfter" option.
bsoncxx::v1::stdx::optional< bsoncxx::v1::document::view > | start_after () const
| Return the current "startAfter" option.
options & | start_after (bsoncxx::v1::document::value v)
| Set the "startAfter" option.
bsoncxx::v1::stdx::optional< bsoncxx::v1::types::b_timestamp > | start_at_operation_time () const
| Return the current "startAtOperationTime" option.
options & | start_at_operation_time (bsoncxx::v1::types::b_timestamp v)
| Set the "startAtOperationTime" option.

## Constructor & Destructor Documentation

## ~options()

mongocxx::v1::change_stream::options::~options | ( |  | ) |

Destroy this object.

Warning
  Invalidates all associated views.

## options() [1/3]

mongocxx::v1::change_stream::options::options | ( | options && | other | ) |

noexcept

Move constructor.

Postconditions:
  - other is in an assign-or-destroy-only state.

## options() [2/3]

mongocxx::v1::change_stream::options::options | ( | options const & | other | ) |

Copy construction.

## options() [3/3]

mongocxx::v1::change_stream::options::options | ( |  | ) |

Default initialization.

Postconditions:
  - All supported fields are "unset" or zero-initialized.

## Member Function Documentation

## batch_size() [1/2]

bsoncxx::v1::stdx::optional< std::int32_t > mongocxx::v1::change_stream::options::batch_size | ( |  | ) | const

Return the current "batchSize" option.

## batch_size() [2/2]

options & mongocxx::v1::change_stream::options::batch_size | ( | std::int32_t | v | ) |

Set the "batchSize" option.

## collation() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::document::view > mongocxx::v1::change_stream::options::collation | ( |  | ) | const

Return the current "collation" option.

## collation() [2/2]

options & mongocxx::v1::change_stream::options::collation | ( | bsoncxx::v1::document::value | v | ) |

Set the "collation" option.

## comment() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::types::view > mongocxx::v1::change_stream::options::comment | ( |  | ) | const

Return the current "comment" option.

## comment() [2/2]

options & mongocxx::v1::change_stream::options::comment | ( | bsoncxx::v1::types::value | v | ) |

Set the "comment" option.

## full_document() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::stdx::string_view > mongocxx::v1::change_stream::options::full_document | ( |  | ) | const

Return the current "fullDocument" option.

## full_document() [2/2]

options & mongocxx::v1::change_stream::options::full_document | ( | std::string | v | ) |

Set the "fullDocument" option.

## full_document_before_change() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::stdx::string_view > mongocxx::v1::change_stream::options::full_document_before_change | ( |  | ) | const

Return the current "fullDocumentBeforeChange" option.

## full_document_before_change() [2/2]

options & mongocxx::v1::change_stream::options::full_document_before_change | ( | std::string | v | ) |

Set the "fullDocumentBeforeChange" option.

## max_await_time() [1/2]

bsoncxx::v1::stdx::optional< std::chrono::milliseconds > mongocxx::v1::change_stream::options::max_await_time | ( |  | ) | const

Return the current "maxAwaitTimeMS" option.

## max_await_time() [2/2]

options & mongocxx::v1::change_stream::options::max_await_time | ( | std::chrono::milliseconds | v | ) |

Set the "maxAwaitTimeMS" option.

## operator=() [1/2]

options & mongocxx::v1::change_stream::options::operator= | ( | options && | other | ) |

noexcept

Move assignment.

Postconditions:
  - other is in an assign-or-destroy-only state.

## operator=() [2/2]

options & mongocxx::v1::change_stream::options::operator= | ( | options const & | other | ) |

Copy assignment.

## resume_after() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::document::view > mongocxx::v1::change_stream::options::resume_after | ( |  | ) | const

Return the current "resumeAfter" option.

Returns
  Empty optional when the "resumeAfter" option is unset.

## resume_after() [2/2]

options & mongocxx::v1::change_stream::options::resume_after | ( | bsoncxx::v1::document::value | v | ) |

Set the "resumeAfter" option.

## start_after() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::document::view > mongocxx::v1::change_stream::options::start_after | ( |  | ) | const

Return the current "startAfter" option.

## start_after() [2/2]

options & mongocxx::v1::change_stream::options::start_after | ( | bsoncxx::v1::document::value | v | ) |

Set the "startAfter" option.

## start_at_operation_time() [1/2]

bsoncxx::v1::stdx::optional< bsoncxx::v1::types::b_timestamp > mongocxx::v1::change_stream::options::start_at_operation_time | ( |  | ) | const

Return the current "startAtOperationTime" option.

## start_at_operation_time() [2/2]

options & mongocxx::v1::change_stream::options::start_at_operation_time | ( | bsoncxx::v1::types::b_timestamp | v | ) |

Set the "startAtOperationTime" option.

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

- mongocxx/v1/change_stream.hpp