parity_scale_codec

Trait EncodeAsRef

Source
pub trait EncodeAsRef<'a, T: 'a> {
    type RefType: Encode + From<&'a T>;
}
Expand description

Something that can be encoded as a reference.

Required Associated Types§

Source

type RefType: Encode + From<&'a T>

The reference type that is used for encoding.

Implementors§

Source§

impl<'a, T: 'a> EncodeAsRef<'a, T> for Compact<T>
where CompactRef<'a, T>: Encode + From<&'a T>,