pub trait OpaqueKeys: Clone {
type KeyTypeIdProviders;
// Required methods
fn key_ids() -> &'static [KeyTypeId];
fn get_raw(&self, i: KeyTypeId) -> &[u8] ⓘ;
// Provided methods
fn get<T: Decode>(&self, i: KeyTypeId) -> Option<T> { ... }
fn ownership_proof_is_valid(&self, _proof: &[u8]) -> bool { ... }
}
Expand description
Opaque data type that may be destructured into a series of raw byte slices (which represent individual keys).
Required Associated Types§
sourcetype KeyTypeIdProviders
type KeyTypeIdProviders
Types bound to this opaque keys that provide the key type ids returned.
Required Methods§
Provided Methods§
sourcefn ownership_proof_is_valid(&self, _proof: &[u8]) -> bool
fn ownership_proof_is_valid(&self, _proof: &[u8]) -> bool
Verify a proof of ownership for the keys.
Object Safety§
This trait is not object safe.