[−][src]Struct lv2_atom::vector::VectorWriter
Handle to append elements to a vector.
This works by allocating a slice of memory behind the vector and then writing your data to it.
Implementations
impl<'a, 'b, A: ScalarAtom> VectorWriter<'a, 'b, A>
[src]
pub fn push(&mut self, child: A::InternalType) -> Option<&mut A::InternalType>
[src]
Push a single value to the vector.
pub fn allocate(&mut self, size: usize) -> Option<&mut [A::InternalType]>
[src]
Append a slice of undefined memory to the vector.
Using this method, you don't need to have the elements in memory before you can write them.
pub fn append(
&mut self,
data: &[A::InternalType]
) -> Option<&mut [A::InternalType]>
[src]
&mut self,
data: &[A::InternalType]
) -> Option<&mut [A::InternalType]>
Append multiple elements to the vector.
Auto Trait Implementations
impl<'a, 'b, A> !RefUnwindSafe for VectorWriter<'a, 'b, A>
impl<'a, 'b, A> !Send for VectorWriter<'a, 'b, A>
impl<'a, 'b, A> !Sync for VectorWriter<'a, 'b, A>
impl<'a, 'b, A> Unpin for VectorWriter<'a, 'b, A> where
A: Unpin,
'a: 'b,
A: Unpin,
'a: 'b,
impl<'a, 'b, A> !UnwindSafe for VectorWriter<'a, 'b, A>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,