Trait gstd::prelude::EncodeLike

source ·
pub trait EncodeLike<T = Self>: Sized + Encode
where T: Encode,
{ }
Expand description

A marker trait that tells the compiler that a type encode to the same representation as another type.

E.g. Vec<u8> has the same encoded representation as &[u8].

§Example

fn encode_like<T: Encode, R: EncodeLike<T>>(data: &R) {
    data.encode(); // Valid `T` encoded value.
}

fn main() {
    // Just pass the a reference to the normal tuple.
    encode_like::<(u32, u32), _>(&(1u32, 2u32));
    // Pass a tuple of references
    encode_like::<(u32, u32), _>(&(&1u32, &2u32));
    // Pass a tuple of a reference and a value.
    encode_like::<(u32, u32), _>(&(&1u32, 2u32));
}

§Warning

The relation is not symetric, T implements EncodeLike<U> does not mean U has same representation as T. For instance we could imaging a non zero integer to be encoded to the same representation as the said integer but not the other way around.

§Limitation

Not all possible implementations of EncodeLike are implemented (for instance Box<Box<u32>> does not implement EncodeLike<u32>). To bypass this issue either open a PR to add the new combination or use Ref reference wrapper or define your own wrapper and implement EncodeLike on it as such:

fn encode_like<T: Encode, R: EncodeLike<T>>(data: &R) {
    data.encode(); // Valid `T` encoded value.
}

struct MyWrapper<'a>(&'a (Box<Box<u32>>, u32));
impl<'a> core::ops::Deref for MyWrapper<'a> { // Or use derive_deref crate
    type Target = (Box<Box<u32>>, u32);
    fn deref(&self) -> &Self::Target { &self.0 }
}

impl<'a> parity_scale_codec::WrapperTypeEncode for MyWrapper<'a> {}
impl<'a> parity_scale_codec::EncodeLike<(u32, u32)> for MyWrapper<'a> {}

fn main() {
    let v = (Box::new(Box::new(0)), 0);
    encode_like::<(u32, u32), _>(&MyWrapper(&v));
}

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl EncodeLike for TypeDefPrimitive

source§

impl EncodeLike for bool

source§

impl EncodeLike for f32

source§

impl EncodeLike for f64

source§

impl EncodeLike for i8

source§

impl EncodeLike for i16

source§

impl EncodeLike for i32

source§

impl EncodeLike for i64

source§

impl EncodeLike for i128

source§

impl EncodeLike for u8

source§

impl EncodeLike for u16

source§

impl EncodeLike for u32

source§

impl EncodeLike for u64

source§

impl EncodeLike for u128

source§

impl EncodeLike for ()

source§

impl EncodeLike for H128

source§

impl EncodeLike for H160

source§

impl EncodeLike for H256

source§

impl EncodeLike for H384

source§

impl EncodeLike for H512

source§

impl EncodeLike for H768

source§

impl EncodeLike for U128

source§

impl EncodeLike for U256

source§

impl EncodeLike for U512

source§

impl EncodeLike for PortableRegistry

source§

impl EncodeLike for PortableType

source§

impl EncodeLike<String> for &str

source§

impl<A0, A1, B0, B1, C0, C1, D0, D1, E0, E1, F0, F1, G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(A1, B1, C1, D1, E1, F1, G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (A0, B0, C0, D0, E0, F0, G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where A0: EncodeLike<A1>, A1: Encode, B0: EncodeLike<B1>, B1: Encode, C0: EncodeLike<C1>, C1: Encode, D0: EncodeLike<D1>, D1: Encode, E0: EncodeLike<E1>, E1: Encode, F0: EncodeLike<F1>, F1: Encode, G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<B0, B1, C0, C1, D0, D1, E0, E1, F0, F1, G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(B1, C1, D1, E1, F1, G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (B0, C0, D0, E0, F0, G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where B0: EncodeLike<B1>, B1: Encode, C0: EncodeLike<C1>, C1: Encode, D0: EncodeLike<D1>, D1: Encode, E0: EncodeLike<E1>, E1: Encode, F0: EncodeLike<F1>, F1: Encode, G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<C0, C1, D0, D1, E0, E1, F0, F1, G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(C1, D1, E1, F1, G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (C0, D0, E0, F0, G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where C0: EncodeLike<C1>, C1: Encode, D0: EncodeLike<D1>, D1: Encode, E0: EncodeLike<E1>, E1: Encode, F0: EncodeLike<F1>, F1: Encode, G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<D0, D1, E0, E1, F0, F1, G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(D1, E1, F1, G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (D0, E0, F0, G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where D0: EncodeLike<D1>, D1: Encode, E0: EncodeLike<E1>, E1: Encode, F0: EncodeLike<F1>, F1: Encode, G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<E0, E1, F0, F1, G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(E1, F1, G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (E0, F0, G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where E0: EncodeLike<E1>, E1: Encode, F0: EncodeLike<F1>, F1: Encode, G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<F0, F1, G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(F1, G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (F0, G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where F0: EncodeLike<F1>, F1: Encode, G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<G0, G1, H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(G1, H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (G0, H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where G0: EncodeLike<G1>, G1: Encode, H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<H0, H1, I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(H1, I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (H0, I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where H0: EncodeLike<H1>, H1: Encode, I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<I0, I1, J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(I1, J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (I0, J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where I0: EncodeLike<I1>, I1: Encode, J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<J0, J1, K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(J1, K1, L1, M1, N1, O1, P1, Q1, R1)> for (J0, K0, L0, M0, N0, O0, P0, Q0, R0)
where J0: EncodeLike<J1>, J1: Encode, K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<K0, K1, L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(K1, L1, M1, N1, O1, P1, Q1, R1)> for (K0, L0, M0, N0, O0, P0, Q0, R0)
where K0: EncodeLike<K1>, K1: Encode, L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<K, LikeK, V, LikeV> EncodeLike<BTreeMap<LikeK, LikeV>> for &[(K, V)]
where K: EncodeLike<LikeK>, LikeK: Encode, V: EncodeLike<LikeV>, LikeV: Encode,

source§

impl<L0, L1, M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(L1, M1, N1, O1, P1, Q1, R1)> for (L0, M0, N0, O0, P0, Q0, R0)
where L0: EncodeLike<L1>, L1: Encode, M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<M0, M1, N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(M1, N1, O1, P1, Q1, R1)> for (M0, N0, O0, P0, Q0, R0)
where M0: EncodeLike<M1>, M1: Encode, N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<N0, N1, O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(N1, O1, P1, Q1, R1)> for (N0, O0, P0, Q0, R0)
where N0: EncodeLike<N1>, N1: Encode, O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<O0, O1, P0, P1, Q0, Q1, R0, R1> EncodeLike<(O1, P1, Q1, R1)> for (O0, P0, Q0, R0)
where O0: EncodeLike<O1>, O1: Encode, P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<P0, P1, Q0, Q1, R0, R1> EncodeLike<(P1, Q1, R1)> for (P0, Q0, R0)
where P0: EncodeLike<P1>, P1: Encode, Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<Q0, Q1, R0, R1> EncodeLike<(Q1, R1)> for (Q0, R0)
where Q0: EncodeLike<Q1>, Q1: Encode, R0: EncodeLike<R1>, R1: Encode,

source§

impl<R0, R1> EncodeLike<(R1,)> for (R0,)
where R0: EncodeLike<R1>, R1: Encode,

source§

impl<T> EncodeLike for TypeDef<T>

source§

impl<T> EncodeLike for &T
where T: Encode + ?Sized,

source§

impl<T> EncodeLike for &mut T
where T: Encode + ?Sized,

source§

impl<T> EncodeLike for Arc<T>
where T: Encode + ?Sized,

source§

impl<T> EncodeLike for UntrackedSymbol<T>
where PhantomData<fn() -> T>: Encode,

source§

impl<T> EncodeLike for TypeDefComposite<T>
where T: Form, Vec<Field<T>>: Encode,

source§

impl<T> EncodeLike for Field<T>
where T: Form, Option<<T as Form>::String>: Encode, <T as Form>::Type: Encode, Vec<<T as Form>::String>: Encode,

source§

impl<T> EncodeLike for Path<T>
where T: Form, Vec<<T as Form>::String>: Encode,

source§

impl<T> EncodeLike for Type<T>
where T: Form, Path<T>: Encode, Vec<TypeParameter<T>>: Encode, TypeDef<T>: Encode, Vec<<T as Form>::String>: Encode,

source§

impl<T> EncodeLike for TypeDefArray<T>
where T: Form, <T as Form>::Type: Encode,

source§

impl<T> EncodeLike for TypeDefBitSequence<T>
where T: Form, <T as Form>::Type: Encode,

source§

impl<T> EncodeLike for TypeDefCompact<T>
where T: Form, <T as Form>::Type: Encode,

source§

impl<T> EncodeLike for TypeDefSequence<T>
where T: Form, <T as Form>::Type: Encode,

source§

impl<T> EncodeLike for TypeDefTuple<T>
where T: Form, Vec<<T as Form>::Type>: Encode,

source§

impl<T> EncodeLike for TypeParameter<T>
where T: Form, <T as Form>::String: Encode, Option<<T as Form>::Type>: Encode,

source§

impl<T> EncodeLike for TypeDefVariant<T>
where T: Form, Vec<Variant<T>>: Encode,

source§

impl<T> EncodeLike for Variant<T>
where T: Form, <T as Form>::String: Encode, Vec<Field<T>>: Encode, Vec<<T as Form>::String>: Encode,

source§

impl<T> EncodeLike<T> for &&T
where T: Encode,

source§

impl<T> EncodeLike<T> for &T
where T: Encode,

source§

impl<T> EncodeLike<T> for &mut T
where T: Encode,

source§

impl<T> EncodeLike<T> for Arc<T>
where T: Encode,

source§

impl<T, LikeT> EncodeLike<BTreeSet<LikeT>> for &[(T,)]
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<BinaryHeap<LikeT>> for &[(T,)]
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<LinkedList<LikeT>> for &[(T,)]
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, U> EncodeLike<VecDeque<U>> for &[T]
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U> EncodeLike<Vec<U>> for &[T]
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U, const N: usize> EncodeLike<[U; N]> for [T; N]
where T: EncodeLike<U>, U: Encode,

Implementors§

source§

impl EncodeLike for ErrorReplyReason

source§

impl EncodeLike for ReplyCode

source§

impl EncodeLike for SignalCode

source§

impl EncodeLike for SimpleExecutionError

source§

impl EncodeLike for SimpleProgramCreationError

source§

impl EncodeLike for SuccessReplyReason

source§

impl EncodeLike for ActorId

source§

impl EncodeLike for CodeId

source§

impl EncodeLike for MessageId

source§

impl EncodeLike for Reservation

source§

impl EncodeLike for ReservationId

source§

impl EncodeLike for Reservations

source§

impl EncodeLike for OptionBool

source§

impl EncodeLike for NonZero<i8>

source§

impl EncodeLike for NonZero<i16>

source§

impl EncodeLike for NonZero<i32>

source§

impl EncodeLike for NonZero<i64>

source§

impl EncodeLike for NonZero<i128>

source§

impl EncodeLike for NonZero<u8>

source§

impl EncodeLike for NonZero<u16>

source§

impl EncodeLike for NonZero<u32>

source§

impl EncodeLike for NonZero<u64>

source§

impl EncodeLike for NonZero<u128>

source§

impl EncodeLike for String

source§

impl EncodeLike for Duration

source§

impl EncodeLike<&str> for String

source§

impl<'a, T> EncodeLike for Cow<'a, T>
where T: ToOwned + Encode + ?Sized,

source§

impl<'a, T> EncodeLike for CompactRef<'a, T>
where T: CompactAs, CompactRef<'b, <T as CompactAs>::As>: for<'b> Encode,

source§

impl<'a, T> EncodeLike<Cow<'a, T>> for T
where T: ToOwned + Encode,

source§

impl<'a, T> EncodeLike<T> for Cow<'a, T>
where T: ToOwned + Encode,

source§

impl<'a, T, U> EncodeLike<U> for &Ref<'a, T, U>
where T: EncodeLike<U>, U: Encode,

source§

impl<'a, T, U> EncodeLike<U> for Ref<'a, T, U>
where T: EncodeLike<U>, U: Encode,

source§

impl<K, LikeK, V, LikeV> EncodeLike<&[(LikeK, LikeV)]> for BTreeMap<K, V>
where K: EncodeLike<LikeK>, LikeK: Encode, V: EncodeLike<LikeV>, LikeV: Encode,

source§

impl<K, LikeK, V, LikeV> EncodeLike<BTreeMap<LikeK, LikeV>> for BTreeMap<K, V>
where K: EncodeLike<LikeK>, LikeK: Encode, V: EncodeLike<LikeV>, LikeV: Encode,

source§

impl<T> EncodeLike for VecDeque<T>
where T: Encode,

source§

impl<T> EncodeLike for Compact<T>
where CompactRef<'a, T>: for<'a> Encode,

source§

impl<T> EncodeLike for PhantomData<T>

source§

impl<T> EncodeLike for Rc<T>
where T: Encode + ?Sized,

source§

impl<T> EncodeLike for Box<T>
where T: Encode + ?Sized,

source§

impl<T> EncodeLike<&&T> for T
where T: Encode,

source§

impl<T> EncodeLike<&T> for T
where T: Encode,

source§

impl<T> EncodeLike<&mut T> for T
where T: Encode,

source§

impl<T> EncodeLike<Arc<T>> for T
where T: Encode,

source§

impl<T> EncodeLike<Rc<T>> for T
where T: Encode,

source§

impl<T> EncodeLike<Box<T>> for T
where T: Encode,

source§

impl<T> EncodeLike<T> for Rc<T>
where T: Encode,

source§

impl<T> EncodeLike<T> for Box<T>
where T: Encode,

source§

impl<T, LikeT> EncodeLike<&[(LikeT,)]> for BTreeSet<T>
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<&[(LikeT,)]> for BinaryHeap<T>
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<&[(LikeT,)]> for LinkedList<T>
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<BTreeSet<LikeT>> for BTreeSet<T>
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<BinaryHeap<LikeT>> for BinaryHeap<T>
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT> EncodeLike<LinkedList<LikeT>> for LinkedList<T>
where T: EncodeLike<LikeT>, LikeT: Encode,

source§

impl<T, LikeT, E, LikeE> EncodeLike<Result<LikeT, LikeE>> for Result<T, E>
where T: EncodeLike<LikeT>, LikeT: Encode, E: EncodeLike<LikeE>, LikeE: Encode,

source§

impl<T, U> EncodeLike<&[U]> for VecDeque<T>
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U> EncodeLike<&[U]> for Vec<T>
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U> EncodeLike<Option<U>> for Option<T>
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U> EncodeLike<VecDeque<U>> for Vec<T>
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U> EncodeLike<Vec<U>> for VecDeque<T>
where T: EncodeLike<U>, U: Encode,

source§

impl<T, U> EncodeLike<Vec<U>> for Vec<T>
where T: EncodeLike<U>, U: Encode,