#[non_exhaustive]#[repr(u64)]pub enum KnownMultiCodec {
Show 22 variants
Identity = 0,
Sha1 = 17,
Sha2256 = 18,
Sha2512 = 19,
Sha3512 = 20,
Sha3384 = 21,
Sha3256 = 22,
Sha3224 = 23,
Shake128 = 24,
Shake256 = 25,
Keccak224 = 26,
Keccak256 = 27,
Keccak384 = 28,
Keccak512 = 29,
Blake3 = 30,
Sha2384 = 32,
Raw = 85,
DagPb = 112,
DagCbor = 113,
DagJson = 297,
CoEncryptedBlock = 3_149_824,
CoReference = 3_149_825,
}Expand description
Known Muiticodecs See: https://github.com/multiformats/multicodec/blob/master/table.csv
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Identity = 0
Tag: multihash Status: permanent
Sha1 = 17
Tag: multihash Status: permanent
Sha2256 = 18
Tag: multihash Status: permanent
Sha2512 = 19
Tag: multihash Status: permanent
Sha3512 = 20
Tag: multihash Status: permanent
Sha3384 = 21
Tag: multihash Status: permanent
Sha3256 = 22
Tag: multihash Status: permanent
Sha3224 = 23
Tag: multihash Status: permanent
Shake128 = 24
Tag: multihash Status: draft
Shake256 = 25
Tag: multihash Status: draft
Keccak224 = 26
keccak has variable output length. The number specifies the core length Tag: multihash Status: draft
Keccak256 = 27
Tag: multihash Status: draft
Keccak384 = 28
Tag: multihash Status: draft
Keccak512 = 29
Tag: multihash Status: draft
Blake3 = 30
BLAKE3 has a default 32 byte output length. The maximum length is (2^64)-1 bytes. Tag: multihash Status: draft
Sha2384 = 32
aka SHA-384; as specified by FIPS 180-4. Tag: multihash Status: permanent
Raw = 85
raw binary Tag: ipld Status: permanent
DagPb = 112
MerkleDAG protobuf Tag: ipld Status: permanent
DagCbor = 113
MerkleDAG cbor Tag: ipld Status: permanent
DagJson = 297
MerkleDAG json Tag: ipld Status: permanent
CoEncryptedBlock = 3_149_824
Co Encrypted Block wrapped in KnownMultiCodec::DagCbor.
CoReference = 3_149_825
Implementations§
Source§impl KnownMultiCodec
impl KnownMultiCodec
pub fn multi_codec(&self) -> MultiCodec
Trait Implementations§
Source§impl Clone for KnownMultiCodec
impl Clone for KnownMultiCodec
Source§fn clone(&self) -> KnownMultiCodec
fn clone(&self) -> KnownMultiCodec
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for KnownMultiCodec
impl Debug for KnownMultiCodec
Source§impl<'de> Deserialize<'de> for KnownMultiCodec
impl<'de> Deserialize<'de> for KnownMultiCodec
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Source§impl From<KnownMultiCodec> for MultiCodec
impl From<KnownMultiCodec> for MultiCodec
Source§fn from(value: KnownMultiCodec) -> Self
fn from(value: KnownMultiCodec) -> Self
Source§impl From<KnownMultiCodec> for u64
impl From<KnownMultiCodec> for u64
Source§fn from(value: KnownMultiCodec) -> Self
fn from(value: KnownMultiCodec) -> Self
Source§impl Ord for KnownMultiCodec
impl Ord for KnownMultiCodec
Source§fn cmp(&self, other: &KnownMultiCodec) -> Ordering
fn cmp(&self, other: &KnownMultiCodec) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq<KnownMultiCodec> for MultiCodec
impl PartialEq<KnownMultiCodec> for MultiCodec
Source§impl PartialEq<u64> for KnownMultiCodec
impl PartialEq<u64> for KnownMultiCodec
Source§impl PartialEq for KnownMultiCodec
impl PartialEq for KnownMultiCodec
Source§impl PartialOrd for KnownMultiCodec
impl PartialOrd for KnownMultiCodec
Source§impl Serialize for KnownMultiCodec
impl Serialize for KnownMultiCodec
Source§impl TryFrom<u64> for KnownMultiCodec
impl TryFrom<u64> for KnownMultiCodec
impl Copy for KnownMultiCodec
impl Eq for KnownMultiCodec
impl StructuralPartialEq for KnownMultiCodec
Auto Trait Implementations§
impl Freeze for KnownMultiCodec
impl RefUnwindSafe for KnownMultiCodec
impl Send for KnownMultiCodec
impl Sync for KnownMultiCodec
impl Unpin for KnownMultiCodec
impl UnsafeUnpin for KnownMultiCodec
impl UnwindSafe for KnownMultiCodec
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more