pub trait ArrayCodecTraits: CodecTraits {
// Required method
fn recommended_concurrency(
&self,
shape: &[NonZero<u64>],
data_type: &DataType,
) -> Result<RecommendedConcurrency, CodecError>;
// Provided method
fn partial_decode_granularity(
&self,
shape: &[NonZero<u64>],
) -> Vec<NonZero<u64>> { ... }
}Expand description
Traits for both array to array and array to bytes codecs.
Required Methods§
Sourcefn recommended_concurrency(
&self,
shape: &[NonZero<u64>],
data_type: &DataType,
) -> Result<RecommendedConcurrency, CodecError>
fn recommended_concurrency( &self, shape: &[NonZero<u64>], data_type: &DataType, ) -> Result<RecommendedConcurrency, CodecError>
Return the recommended concurrency for the requested decoded representation.
§Errors
Returns CodecError if the decoded representation is not valid for the codec.
Provided Methods§
Sourcefn partial_decode_granularity(
&self,
shape: &[NonZero<u64>],
) -> Vec<NonZero<u64>>
fn partial_decode_granularity( &self, shape: &[NonZero<u64>], ) -> Vec<NonZero<u64>>
Return the partial decode granularity.
This represents the shape of the smallest subset of a chunk that can be efficiently decoded if the chunk were subdivided into a regular grid. For most codecs, this is just the shape of the chunk. It is the shape of the sub chunks (inner chunks) for the sharding codec.
Implementors§
impl ArrayCodecTraits for BitroundCodec
Available on crate feature
bitround only.impl ArrayCodecTraits for FixedScaleOffsetCodec
impl ArrayCodecTraits for ReshapeCodec
impl ArrayCodecTraits for SqueezeCodec
impl ArrayCodecTraits for TransposeCodec
Available on crate feature
transpose only.impl ArrayCodecTraits for BytesCodec
impl ArrayCodecTraits for CodecChain
impl ArrayCodecTraits for OptionalCodec
impl ArrayCodecTraits for PackBitsCodec
impl ArrayCodecTraits for PcodecCodec
Available on crate feature
pcodec only.impl ArrayCodecTraits for ShardingCodec
Available on crate feature
sharding only.impl ArrayCodecTraits for VlenCodec
impl ArrayCodecTraits for VlenArrayCodec
impl ArrayCodecTraits for VlenBytesCodec
impl ArrayCodecTraits for VlenUtf8Codec
impl ArrayCodecTraits for VlenV2Codec
impl ArrayCodecTraits for ZfpCodec
Available on crate feature
zfp only.impl ArrayCodecTraits for ZfpyCodec
Available on crate feature
zfp only.