76 if (_full_document_before_change) {
100 if (_max_await_time) {
104 if (_start_at_operation_time) {
139 _full_document = std::move(full_doc);
150 return _full_document;
173 _full_document_before_change = std::move(full_doc_before_change);
185 return _full_document_before_change;
265 return _resume_after;
286 _start_after = std::move(token);
337 _max_await_time = max_time;
348 return _max_await_time;
366 _start_at_operation_time = std::move(timestamp);
377 return _start_at_operation_time;
405 return {std::move(v)};
A BSON document.
Definition value.hpp:46
A polyfill for std::optional<T>.
Definition optional.hpp:799
A union of BSON type values.
Definition value.hpp:54
A view-or-value variant type for strings.
Definition view_or_value.hpp:41
change_stream()=default
Default initialization.
Options for mongocxx::v1::change_stream.
Definition change_stream.hpp:174
options & collation(bsoncxx::v1::document::value v)
Set the "collation" option.
options & batch_size(std::int32_t v)
Set the "batchSize" option.
options & start_at_operation_time(bsoncxx::v1::types::b_timestamp v)
Set the "startAtOperationTime" option.
options & resume_after(bsoncxx::v1::document::value v)
Set the "resumeAfter" option.
options & start_after(bsoncxx::v1::document::value v)
Set the "startAfter" option.
options & max_await_time(std::chrono::milliseconds v)
Set the "maxAwaitTimeMS" option.
options & comment(bsoncxx::v1::types::value v)
Set the "comment" option.
options & full_document_before_change(std::string v)
Set the "fullDocumentBeforeChange" option.
options & full_document(std::string v)
Set the "fullDocument" option.
Used by change streams.
Definition change_stream.hpp:52
bsoncxx::v_noabi::stdx::optional< std::chrono::milliseconds > const & max_await_time() const
The current max_time setting.
Definition change_stream.hpp:347
change_stream & resume_after(bsoncxx::v_noabi::document::view_or_value resume_after)
Specifies the logical starting point for the new change stream.
Definition change_stream.hpp:253
change_stream & batch_size(std::int32_t batch_size)
Sets the number of documents to return per batch.
Definition change_stream.hpp:198
bsoncxx::v_noabi::stdx::optional< bsoncxx::v_noabi::types::bson_value::view_or_value > const & comment() const
Gets the current value of the comment option.
Definition change_stream.hpp:234
bsoncxx::v_noabi::stdx::optional< bsoncxx::v_noabi::string::view_or_value > const & full_document() const
Gets the current fullDocument option.
Definition change_stream.hpp:149
change_stream & start_after(bsoncxx::v_noabi::document::view_or_value token)
Specifies the logical starting point of the new change stream. The new stream will return the first n...
Definition change_stream.hpp:285
bsoncxx::v_noabi::stdx::optional< std::int32_t > const & batch_size() const
The current batch size setting.
Definition change_stream.hpp:209
change_stream & start_at_operation_time(bsoncxx::v_noabi::types::b_timestamp timestamp)
Specifies the logical starting point for the new change stream. Changes are returned at or after the ...
Definition change_stream.hpp:365
change_stream & max_await_time(std::chrono::milliseconds max_time)
Sets the maximum amount of time for for the server to wait on new documents to satisfy a change strea...
Definition change_stream.hpp:336
change_stream & full_document(bsoncxx::v_noabi::string::view_or_value full_doc)
Sets the fullDocument option for the $changeStream.
Definition change_stream.hpp:138
change_stream & collation(bsoncxx::v_noabi::document::view_or_value collation)
Sets the collation for this operation.
Definition change_stream.hpp:310
change_stream & full_document_before_change(bsoncxx::v_noabi::string::view_or_value full_doc_before_change)
Sets the fullDocumentBeforeChange option for the $changeStream.
Definition change_stream.hpp:172
bsoncxx::v_noabi::stdx::optional< bsoncxx::v_noabi::document::view_or_value > const & collation() const
Retrieves the current collation for this operation.
Definition change_stream.hpp:321
operator v1::change_stream::options() const
Convert to the mongocxx::v1 equivalent.
Definition change_stream.hpp:67
change_stream()=default
Default initialization.
bsoncxx::v_noabi::stdx::optional< bsoncxx::v_noabi::string::view_or_value > const & full_document_before_change() const
Gets the current fullDocumentBeforeChange option.
Definition change_stream.hpp:183
change_stream & comment(bsoncxx::v_noabi::types::bson_value::view_or_value comment)
Sets the current value of the comment option.
Definition change_stream.hpp:223
bsoncxx::v_noabi::stdx::optional< bsoncxx::v_noabi::document::view_or_value > const & start_after() const
Retrieves the current startAfter token for this change stream.
Definition change_stream.hpp:296
bsoncxx::v_noabi::stdx::optional< bsoncxx::v_noabi::document::view_or_value > const & resume_after() const
Retrieves the current resumeToken for this change stream.
Definition change_stream.hpp:264
bsoncxx::stdx::optional< bsoncxx::v_noabi::types::b_timestamp > const & start_at_operation_time() const
The current start_at_operation_time setting.
Definition change_stream.hpp:376
Provides bsoncxx::v_noabi::document::view_or_value.
#define MONGOCXX_ABI_EXPORT_CDECL(...)
Equivalent to MONGOCXX_ABI_EXPORT with MONGOCXX_ABI_CDECL.
Definition export.hpp:52
The mongocxx v_noabi macro guard postlude header.
The mongocxx v_noabi macro guard prelude header.
v_noabi::view_or_value< v_noabi::document::view, v_noabi::document::value > view_or_value
Equivalent to v_noabi::view_or_value<v_noabi::document::view, v_noabi::document::value>.
Definition view_or_value.hpp:30
v_noabi::view_or_value< view, value > view_or_value
Equivalent to v_noabi::view_or_value<view, value>.
Definition view_or_value.hpp:31
v1::element::view to_v1(v_noabi::array::element const &v)
Convert to the bsoncxx::v1 equivalent of v.
Definition element.hpp:132
Declares entities whose ABI stability is guaranteed for documented symbols.
Declares entities representing options to use with various commands.
Declares entities whose ABI stability is NOT guaranteed.
v1::bulk_write to_v1(v_noabi::bulk_write v)
Convert to the mongocxx::v1 equivalent of v.
Definition bulk_write.hpp:162
v_noabi::bulk_write from_v1(v1::bulk_write v)
Convert to the mongocxx::v_noabi equivalent of v.
Definition bulk_write.hpp:155
The top-level namespace within which all mongocxx library entities are declared.
Provides bsoncxx::v_noabi::string::view_or_value.
A BSON replication timestamp value.
Definition types.hpp:601
Provides bsoncxx::v_noabi::types::bson_value::view_or_value.
Provides entities used to represent BSON types.
Provides mongocxx::v1::change_stream.
Provides bsoncxx::v1::types::value.
Provides bsoncxx::v_noabi::document::value.
Provides bsoncxx::v_noabi::document::view.
Provides std::optional-related polyfills for library API usage.
Provides bsoncxx::v_noabi::types::bson_value::view.
Declares mongocxx::v_noabi::client.
Declares mongocxx::v_noabi::collection.
Declares mongocxx::v_noabi::database.
Declares mongocxx::v_noabi::options::change_stream.