pub trait AsyncArrayPartialDecoderTraits:
Any
+ Send
+ Sync {
// Required methods
fn data_type(&self) -> &DataType;
fn exists<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<bool, StorageError>> + Send + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn size_held(&self) -> usize;
fn partial_decode<'a, 'life0, 'life1, 'async_trait>(
&'a self,
indexer: &'life0 dyn Indexer,
options: &'life1 CodecOptions,
) -> Pin<Box<dyn Future<Output = Result<ArrayBytes<'a>, CodecError>> + Send + 'async_trait>>
where 'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
fn supports_partial_decode(&self) -> bool;
// Provided method
fn partial_decode_into<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
indexer: &'life1 dyn Indexer,
output_target: ArrayBytesDecodeIntoTarget<'life2>,
options: &'life3 CodecOptions,
) -> Pin<Box<dyn Future<Output = Result<(), CodecError>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait { ... }
}Available on crate feature
async only.Expand description
Asynchronous partial array decoder traits.
Required Methods§
Sourcefn exists<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<bool, StorageError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn exists<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<bool, StorageError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Sourcefn size_held(&self) -> usize
fn size_held(&self) -> usize
Returns the size of chunk bytes held by the partial decoder.
Intended for use by size-constrained partial decoder caches.
Sourcefn partial_decode<'a, 'life0, 'life1, 'async_trait>(
&'a self,
indexer: &'life0 dyn Indexer,
options: &'life1 CodecOptions,
) -> Pin<Box<dyn Future<Output = Result<ArrayBytes<'a>, CodecError>> + Send + 'async_trait>>where
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn partial_decode<'a, 'life0, 'life1, 'async_trait>(
&'a self,
indexer: &'life0 dyn Indexer,
options: &'life1 CodecOptions,
) -> Pin<Box<dyn Future<Output = Result<ArrayBytes<'a>, CodecError>> + Send + 'async_trait>>where
'a: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Partially decode a chunk.
§Errors
Returns CodecError if a codec fails, array subset is invalid, or the array subset shape does not match array view subset shape.
Sourcefn supports_partial_decode(&self) -> bool
fn supports_partial_decode(&self) -> bool
Returns whether this decoder supports partial decoding.
If this returns true, the decoder can efficiently handle partial decoding operations.
If this returns false, partial decoding will fall back to a full decode operation.
Provided Methods§
Sourcefn partial_decode_into<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
indexer: &'life1 dyn Indexer,
output_target: ArrayBytesDecodeIntoTarget<'life2>,
options: &'life3 CodecOptions,
) -> Pin<Box<dyn Future<Output = Result<(), CodecError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
fn partial_decode_into<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
indexer: &'life1 dyn Indexer,
output_target: ArrayBytesDecodeIntoTarget<'life2>,
options: &'life3 CodecOptions,
) -> Pin<Box<dyn Future<Output = Result<(), CodecError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Self: Sync + 'async_trait,
Async variant of ArrayPartialDecoderTraits::partial_decode_into.