-
#include "tensorstore/kvstore/operations.h"
- struct tensorstore::kvstore::ReadGenerationConditions;
Specifies constraints on the generation for read operations.
Data members¶
- StorageGeneration if_not_equal;
The read is aborted if the generation associated with the stored key matches
if_not_equal
. The special values ofStorageGeneration::Unknown()
(the default) orStorageGeneration::NoValue()
disable this condition.
- StorageGeneration if_equal;
The read is aborted if the generation associated with the stored key does not match
if_equal
. This is primarily useful in conjunction with aReadOptions::byte_range
request to ensure consistency.
Methods¶
- bool Matches(const StorageGeneration& generation) const;
Returns
true
ifgeneration
satisfies the constraints.
Conversion operators¶
- explicit operator bool() const;
Indicates if any constraints are specified.