Struct yrs::types::array::ArrayPrelim
source · pub struct ArrayPrelim<T, V>(/* private fields */)
where
T: IntoIterator<Item = V>;
Expand description
A preliminary array. It’s can be used to initialize an YArray, when it’s about to be nested into another Yrs data collection, such as [Map] or another YArray.
Trait Implementations§
source§impl<T, V> From<T> for ArrayPrelim<T, V>where
T: IntoIterator<Item = V>,
impl<T, V> From<T> for ArrayPrelim<T, V>where
T: IntoIterator<Item = V>,
source§impl<T, V> Into<EmbedPrelim<ArrayPrelim<T, V>>> for ArrayPrelim<T, V>where
T: IntoIterator<Item = V>,
impl<T, V> Into<EmbedPrelim<ArrayPrelim<T, V>>> for ArrayPrelim<T, V>where
T: IntoIterator<Item = V>,
source§fn into(self) -> EmbedPrelim<ArrayPrelim<T, V>>
fn into(self) -> EmbedPrelim<ArrayPrelim<T, V>>
Converts this type into the (usually inferred) input type.
source§impl<T, V> Prelim for ArrayPrelim<T, V>where
V: Prelim,
T: IntoIterator<Item = V>,
impl<T, V> Prelim for ArrayPrelim<T, V>where
V: Prelim,
T: IntoIterator<Item = V>,
source§fn into_content(
self,
_txn: &mut TransactionMut<'_>
) -> (ItemContent, Option<Self>)
fn into_content( self, _txn: &mut TransactionMut<'_> ) -> (ItemContent, Option<Self>)
This method is used to create initial content required in order to create a block item.
A supplied
ptr
can be used to identify block that is about to be created to store
the returned content. Read moresource§fn integrate(self, txn: &mut TransactionMut<'_>, inner_ref: BranchPtr)
fn integrate(self, txn: &mut TransactionMut<'_>, inner_ref: BranchPtr)
Method called once an original item filled with content from Self::into_content has been
added to block store. This method is used by complex types such as maps or arrays to append
the original contents of prelim struct into YMap, YArray etc.
Auto Trait Implementations§
impl<T, V> Freeze for ArrayPrelim<T, V>where
T: Freeze,
impl<T, V> RefUnwindSafe for ArrayPrelim<T, V>where
T: RefUnwindSafe,
impl<T, V> Send for ArrayPrelim<T, V>where
T: Send,
impl<T, V> Sync for ArrayPrelim<T, V>where
T: Sync,
impl<T, V> Unpin for ArrayPrelim<T, V>where
T: Unpin,
impl<T, V> UnwindSafe for ArrayPrelim<T, V>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