Struct flex_alloc::vec::config::Custom

source ·
pub struct Custom<C: VecAlloc, I: Index = usize, G: Grow = GrowExact>(/* private fields */);

Implementations§

source§

impl<C: RawAllocNew, I: Index, G: Grow> Custom<C, I, G>

source

pub const fn new() -> Self

Trait Implementations§

source§

impl<C: Debug + VecAlloc, I: Debug + Index, G: Debug + Grow> Debug for Custom<C, I, G>
where C::RawAlloc: Debug,

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<C: Default + VecAlloc, I: Default + Index, G: Default + Grow> Default for Custom<C, I, G>
where C::RawAlloc: Default,

source§

fn default() -> Custom<C, I, G>

Returns the “default value” for a type. Read more
source§

impl<C: VecAlloc, I: Index, G: Grow> VecConfig for Custom<C, I, G>

source§

type Buffer<T> = <C as VecAlloc>::AllocHandle<T, <Custom<C, I, G> as VecConfig>::Index>

source§

type Grow = G

source§

type Index = I

source§

impl<T, C: VecAlloc, I: Index, G: Grow> VecNewIn<T> for Custom<C, I, G>

source§

type Config = Custom<C, I, G>

source§

fn vec_try_new_in( self, capacity: <Self::Config as VecConfig>::Index, exact: bool, ) -> Result<<Self::Config as VecConfig>::Buffer<T>, StorageError>

Auto Trait Implementations§

§

impl<C, I, G> Freeze for Custom<C, I, G>
where <C as VecAlloc>::RawAlloc: Freeze,

§

impl<C, I, G> RefUnwindSafe for Custom<C, I, G>

§

impl<C, I, G> Send for Custom<C, I, G>
where <C as VecAlloc>::RawAlloc: Send, G: Send,

§

impl<C, I, G> Sync for Custom<C, I, G>
where <C as VecAlloc>::RawAlloc: Sync, G: Sync,

§

impl<C, I, G> Unpin for Custom<C, I, G>
where <C as VecAlloc>::RawAlloc: Unpin, I: Unpin, G: Unpin,

§

impl<C, I, G> UnwindSafe for Custom<C, I, G>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T, C> VecConfigNew<T> for C
where C: VecConfigSpawn<T>, <C as VecConfig>::Buffer<T>: VecBufferNew,

source§

const NEW: <C as VecConfig>::Buffer<T> = const NEW: Self::Buffer<T> = <Self::Buffer<T>>::NEW;

source§

fn vec_try_new( capacity: <C as VecConfig>::Index, exact: bool, ) -> Result<<C as VecConfig>::Buffer<T>, StorageError>

source§

impl<T, C> VecConfigSpawn<T> for C
where C: VecConfig, <C as VecConfig>::Buffer<T>: VecBufferSpawn,

source§

fn vec_try_spawn( buf: &<C as VecConfig>::Buffer<T>, capacity: <C as VecConfig>::Index, exact: bool, ) -> Result<<C as VecConfig>::Buffer<T>, StorageError>