Struct brush_lang::test_utils::PrefixedValue
source · [−]Expand description
For calculating the event topic hash.
Fields
prefix: &'a [u8]
value: &'b T
Trait Implementations
sourceimpl<X> Encode for PrefixedValue<'_, '_, X> where
X: Encode,
impl<X> Encode for PrefixedValue<'_, '_, X> where
X: Encode,
sourcefn size_hint(&self) -> usize
fn size_hint(&self) -> usize
If possible give a hint of expected size of the encoding. Read more
sourcefn encode_to<T: Output + ?Sized>(&self, dest: &mut T)
fn encode_to<T: Output + ?Sized>(&self, dest: &mut T)
Convert self to a slice and append it to the destination.
sourcefn using_encoded<R, F>(&self, f: F) -> R where
F: FnOnce(&[u8]) -> R,
fn using_encoded<R, F>(&self, f: F) -> R where
F: FnOnce(&[u8]) -> R,
Convert self to a slice and then invoke the given closure with it.
sourcefn encoded_size(&self) -> usize
fn encoded_size(&self) -> usize
Calculates the encoded size. Read more
Auto Trait Implementations
impl<'a, 'b, T> RefUnwindSafe for PrefixedValue<'a, 'b, T> where
T: RefUnwindSafe,
impl<'a, 'b, T> Send for PrefixedValue<'a, 'b, T> where
T: Sync,
impl<'a, 'b, T> Sync for PrefixedValue<'a, 'b, T> where
T: Sync,
impl<'a, 'b, T> Unpin for PrefixedValue<'a, 'b, T>
impl<'a, 'b, T> UnwindSafe for PrefixedValue<'a, 'b, T> where
T: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more