Trait sov_schema_db::schema::KeyDecoder
source · pub trait KeyDecoder<S: Schema + ?Sized>: Sized + PartialEq + Debug {
// Required method
fn decode_key(data: &[u8]) -> Result<Self>;
}Expand description
Implementors of this trait can be used to decode keys in the given Schema.
Required Methods§
sourcefn decode_key(data: &[u8]) -> Result<Self>
fn decode_key(data: &[u8]) -> Result<Self>
Converts bytes fetched from RocksDB to Self.