This class implements a Zarr abstract store. It provides the
basic plumbing for specific implementations of a Zarr store. It implements
the Zarr abstract store interface, with some extensions from the Python
zarr.abc.store.Store abstract class. Functions set_partial_values() and
get_partial_values() are not implemented.
Active bindings
friendlyClassName(read-only) Name of the class for printing.
read_only(read-only) Flag to indicate if the store is read-only.
supports_consolidated_metadataFlag to indicate if the store can consolidate metadata.
supports_deletesFlag to indicate if keys and arrays can be deleted.
supports_listingFlag to indicate if the store can list its keys.
supports_partial_writesDeprecated, always
FALSE.supports_writesFlag to indicate if the store can write data.
version(read-only) The Zarr version of the store.
separator(read-only) The default separator between elements of chunks of arrays in the store. Every store typically has a default which is used when creating arrays. The actual chunk separator being used is determined by looking at the "chunk_key_encoding" attribute of each array.
Methods
Method new()
Create an instance of this class. Since this class is "abstract", it should not be instantiated directly - it is intended to be called by descendant classes, exclusively.
Usage
zarr_store$new(read_only = FALSE, version = 3L)Method erase()
Remove a key from the store. This method is part of the abstract store interface in ZEP0001.
Method erase_prefix()
Remove all keys and prefixes in the store that begin with a given prefix. This method is part of the abstract store interface in ZEP0001.
Method exists()
Check if a key exists in the store.
Method get()
Retrieve the value associated with a given key. This method is part of the abstract store interface in ZEP0001.
Arguments
keyCharacter string. The key for which to get data.
prototypeIgnored. The only buffer type that is supported maps directly to an R raw vector.
byte_rangeIf
NULL, all data associated with the key is retrieved. If a single positive integer, all bytes starting from a given byte offset to the end of the object are returned. If a single negative integer, the final bytes are returned. If an integer vector of length 2, request a specific range of bytes where the end is exclusive. If the range ends after the end of the object, the entire remainder of the object will be returned. If the given range is zero-length or starts after the end of the object, an error will be returned.
Method getsize_prefix()
Return the size, in bytes, of all objects found under the group indicated by the prefix.
Method list()
Retrieve all keys in the store. This method is part of the abstract store interface in ZEP0001.
Method list_dir()
Retrieve all keys and prefixes with a given prefix and which do not contain the character "/" after the given prefix. This method is part of the abstract store interface in ZEP0001.
Method list_prefix()
Retrieve all keys and prefixes with a given prefix. This method is part of the abstract store interface in ZEP0001.
Method set_if_not_exists()
Store a key to argument value if the key is not already
present. This method is part of the abstract store interface in
ZEP0001.
Method get_metadata()
Retrieve the metadata document of the node at the location
indicated by the prefix argument.
Method set_metadata()
Set the metadata document of the node at the location
indicated by the prefix argument. This is a no-op for stores that
have no writing capability. Other stores must override this method.
Arguments
prefixThe prefix of the node whose metadata document to set.
metadataThe metadata to persist, either a
listor an instance of array_builder.
Method create_group()
Create a new group in the store under the specified path to
the parent argument. The parent path must point to a Zarr group.