Struct VarZeroVecOwned
struct VarZeroVecOwned<T: ?Sized, F = Index16> { ... }
A fully-owned VarZeroVec. This type has no lifetime but has the same
internal buffer representation of VarZeroVec, making it cheaply convertible to
VarZeroVec and VarZeroSlice.
The F type parameter is a VarZeroVecFormat (see its docs for more details), which can be used to select the
precise format of the backing buffer with various size and performance tradeoffs. It defaults to Index16.
Implementations
impl<T: VarULE + ?Sized, F> VarZeroVecOwned<T, F>
fn new() -> SelfConstruct an empty VarZeroVecOwned
impl<T: VarULE + ?Sized, F: VarZeroVecFormat> VarZeroVecOwned<T, F>
fn from_slice(slice: &VarZeroSlice<T, F>) -> SelfConstruct a VarZeroVecOwned from a
VarZeroSliceby cloning the internal datafn try_from_elements<A>(elements: &[A]) -> Result<Self, &'static str> where A: EncodeAsVarULE<T>Construct a VarZeroVecOwned from a list of elements
fn as_slice(self: &Self) -> &VarZeroSlice<T, F>Obtain this
VarZeroVecas aVarZeroSlicefn as_varzerovec<'a>(self: &'a Self) -> VarZeroVec<'a, T, F>Get this
VarZeroVecOwnedas a borrowedVarZeroVecIf you wish to repeatedly call methods on this
VarZeroVecOwned, it is more efficient to perform this conversion firstfn clear(self: &mut Self)Empty the vector
fn into_bytes(self: Self) -> Vec<u8>Consume this vector and return the backing buffer
fn push<A: EncodeAsVarULE<T> + ?Sized>(self: &mut Self, element: &A)Insert an element at the end of this vector
fn insert<A: EncodeAsVarULE<T> + ?Sized>(self: &mut Self, index: usize, element: &A)Insert an element at index
idxfn remove(self: &mut Self, index: usize)Remove the element at index
idxfn replace<A: EncodeAsVarULE<T> + ?Sized>(self: &mut Self, index: usize, element: &A)Replace the element at index
idxwith another
impl<'a, T: ?Sized + VarULE, F: VarZeroVecFormat> From for VarZeroVecOwned<T, F>
fn from(other: VarZeroVec<'a, T, F>) -> Self
impl<'a, T: ?Sized + VarULE, F: VarZeroVecFormat> From for VarZeroVecOwned<T, F>
fn from(other: &'a VarZeroSlice<T, F>) -> Self
impl<P, T> Receiver for VarZeroVecOwned<T, F>
impl<T> Any for VarZeroVecOwned<T, F>
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for VarZeroVecOwned<T, F>
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for VarZeroVecOwned<T, F>
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> CloneToUninit for VarZeroVecOwned<T, F>
unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)
impl<T> ErasedDestructor for VarZeroVecOwned<T, F>
impl<T> From for VarZeroVecOwned<T, F>
fn from(t: T) -> TReturns the argument unchanged.
impl<T> ToOwned for VarZeroVecOwned<T, F>
fn to_owned(self: &Self) -> Tfn clone_into(self: &Self, target: &mut T)
impl<T, A, F> PartialEq for VarZeroVecOwned<T, F>
fn eq(self: &Self, other: &&[A]) -> bool
impl<T, F> Freeze for VarZeroVecOwned<T, F>
impl<T, F> RefUnwindSafe for VarZeroVecOwned<T, F>
impl<T, F> Send for VarZeroVecOwned<T, F>
impl<T, F> Sync for VarZeroVecOwned<T, F>
impl<T, F> Unpin for VarZeroVecOwned<T, F>
impl<T, F> UnsafeUnpin for VarZeroVecOwned<T, F>
impl<T, F> UnwindSafe for VarZeroVecOwned<T, F>
impl<T, F: VarZeroVecFormat> Debug for VarZeroVecOwned<T, F>
fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result
impl<T, U> Into for VarZeroVecOwned<T, F>
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom for VarZeroVecOwned<T, F>
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for VarZeroVecOwned<T, F>
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>
impl<T: ?Sized, F> Clone for VarZeroVecOwned<T, F>
fn clone(self: &Self) -> Self
impl<T: VarULE + ?Sized, F> Default for VarZeroVecOwned<T, F>
fn default() -> Self
impl<T: VarULE + ?Sized, F: VarZeroVecFormat> Deref for VarZeroVecOwned<T, F>
fn deref(self: &Self) -> &VarZeroSlice<T, F>