-
#include "tensorstore/kvstore/kvstore.h"
-
template <typename... Option>
requires IsCompatibleOptionSequence<SpecRequestOptions, Option...>
Result<Spec>
tensorstore::kvstore::KvStore::spec(Option&&... option) const; -
Result<Spec> tensorstore::kvstore::KvStore::spec(
SpecRequestOptions&& options) const; Returns a Spec that can be used to re-open this
KvStore
.Options that modify the returned
Spec
may be specified in any order. The meaning of the option is determined by its type.Supported options are:
ContextBindingMode: Defaults to
ContextBindingMode::strip
, such that the returnedSpec
does not specify any context resources. To retain the bound context resources, such that the returnedSpec
may be used to re-open theKvStore
with the identical context resources, specifyContextBindingMode::retain
. SpecifyingContextBindingMode::unbind
converts all context resources to context resource specs that may be used to re-open theKvStore
with a graph of new context resources isomorphic to the existing graph of context resources.
- Parameters:¶
- Option&&... option¶
Any option compatible with
SpecRequestOptions
.
- Error absl::StatusCode::kUnimplemented:¶
if a JSON representation is not supported. (This behavior is provided by the default implementation.)