-
#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
Specmay 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 returnedSpecdoes not specify any context resources. To retain the bound context resources, such that the returnedSpecmay be used to re-open theKvStorewith the identical context resources, specifyContextBindingMode::retain. SpecifyingContextBindingMode::unbindconverts all context resources to context resource specs that may be used to re-open theKvStorewith 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.)