65 return { base, expiry_, delta_, initial_value_ };
83 expiry_ = core::impl::expiry_relative(duration);
99 expiry_ = core::impl::expiry_absolute(time_point);
129 initial_value_ = value;
134 std::uint32_t expiry_{ 0 };
135 std::uint64_t delta_{ 1 };
136 std::optional<std::uint64_t> initial_value_{};
Common options that used by most operations.
Definition common_durability_options.hxx:39
auto build_common_durability_options() const -> built
Definition common_durability_options.hxx:100
auto self() -> increment_options &
Definition common_options.hxx:116
Represents result of counter operations.
Definition counter_result.hxx:35
Represents a single item from the result of collection::scan()
Definition allow_querying_search_index_options.hxx:28
std::function< void(error, counter_result)> increment_handler
The signature for the handler of the binary_collection::increment() operation.
Definition increment_options.hxx:145
Immutable value object representing consistent options.
Definition increment_options.hxx:45
const std::optional< std::uint64_t > initial_value
Definition increment_options.hxx:48
const std::uint64_t delta
Definition increment_options.hxx:47
const std::uint32_t expiry
Definition increment_options.hxx:46
Options for binary_collection::increment().
Definition increment_options.hxx:38
auto build() const -> built
Validates options and returns them as an immutable value.
Definition increment_options.hxx:62
auto initial(std::uint64_t value) -> increment_options &
The initial value that should be used if the document has not been created yet.
Definition increment_options.hxx:127
auto delta(std::uint64_t delta) -> increment_options &
The amount of which the document value should be incremented.
Definition increment_options.hxx:112
auto expiry(std::chrono::system_clock::time_point time_point) -> increment_options &
Sets the expiry for the document.
Definition increment_options.hxx:97
auto expiry(std::chrono::seconds duration) -> increment_options &
Sets the expiry for the document.
Definition increment_options.hxx:81