#[repr(transparent)]pub struct ArkScale<T, const U: Usage = WIRE>(pub T);Expand description
Arkworks type wrapped for serialization by Scale
Tuple Fields§
§0: TTrait Implementations§
source§impl<T: CanonicalDeserialize, const U: Usage> Decode for ArkScale<T, U>
impl<T: CanonicalDeserialize, const U: Usage> Decode for ArkScale<T, U>
source§fn decode<I: Input>(input: &mut I) -> Result<Self, Error>
fn decode<I: Input>(input: &mut I) -> Result<Self, Error>
Attempt to deserialise the value from input.
source§fn decode_into<I>(
input: &mut I,
dst: &mut MaybeUninit<Self>
) -> Result<DecodeFinished, Error>where
I: Input,
fn decode_into<I>( input: &mut I, dst: &mut MaybeUninit<Self> ) -> Result<DecodeFinished, Error>where I: Input,
Attempt to deserialize the value from input into a pre-allocated piece of memory. Read more
source§impl<T: CanonicalSerialize, const U: Usage> Encode for ArkScale<T, U>
impl<T: CanonicalSerialize, const U: Usage> Encode for ArkScale<T, U>
source§fn size_hint(&self) -> usize
fn size_hint(&self) -> usize
If possible give a hint of expected size of the encoding. Read more
source§fn encode_to<O: Output + ?Sized>(&self, dest: &mut O)
fn encode_to<O: Output + ?Sized>(&self, dest: &mut O)
Convert self to a slice and append it to the destination.
source§fn encoded_size(&self) -> usize
fn encoded_size(&self) -> usize
Calculates the encoded size. Read more
source§fn using_encoded<R, F>(&self, f: F) -> Rwhere
F: FnOnce(&[u8]) -> R,
fn using_encoded<R, F>(&self, f: F) -> Rwhere F: FnOnce(&[u8]) -> R,
Convert self to a slice and then invoke the given closure with it.
source§impl<T> MaxEncodedLen for ArkScale<T, WIRE>where
T: CanonicalSerialize + ArkScaleMaxEncodedLen,
impl<T> MaxEncodedLen for ArkScale<T, WIRE>where T: CanonicalSerialize + ArkScaleMaxEncodedLen,
source§fn max_encoded_len() -> usize
fn max_encoded_len() -> usize
Upper bound, in bytes, of the maximum encoded size of this item.
source§impl<T: PartialEq, const U: Usage> PartialEq<ArkScale<T, U>> for ArkScale<T, U>
impl<T: PartialEq, const U: Usage> PartialEq<ArkScale<T, U>> for ArkScale<T, U>
impl<T: CanonicalSerialize, const U: Usage> EncodeLike<ArkScale<T, U>> for ArkScale<T, U>
impl<T: Eq, const U: Usage> Eq for ArkScale<T, U>
impl<T, const U: Usage> StructuralEq for ArkScale<T, U>
impl<T, const U: Usage> StructuralPartialEq for ArkScale<T, U>
Auto Trait Implementations§
impl<T, const U: u8> RefUnwindSafe for ArkScale<T, U>where T: RefUnwindSafe,
impl<T, const U: u8> Send for ArkScale<T, U>where T: Send,
impl<T, const U: u8> Sync for ArkScale<T, U>where T: Sync,
impl<T, const U: u8> Unpin for ArkScale<T, U>where T: Unpin,
impl<T, const U: u8> UnwindSafe for ArkScale<T, U>where T: UnwindSafe,
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
Mutably borrows from an owned value. Read more