Enum loro_internal::op::InnerContent
source · pub enum InnerContent {
List(InnerListOp),
Map(InnerMapSet),
Tree(TreeOp),
}Variants§
Implementations§
source§impl InnerContent
impl InnerContent
sourcepub fn as_list_mut(&mut self) -> Option<&mut InnerListOp>
pub fn as_list_mut(&mut self) -> Option<&mut InnerListOp>
Optionally returns mutable references to the inner fields if this is a InnerContent::List, otherwise None
sourcepub fn as_list(&self) -> Option<&InnerListOp>
pub fn as_list(&self) -> Option<&InnerListOp>
Optionally returns references to the inner fields if this is a InnerContent::List, otherwise None
sourcepub fn into_list(self) -> Result<InnerListOp, Self>
pub fn into_list(self) -> Result<InnerListOp, Self>
Returns the inner fields if this is a InnerContent::List, otherwise returns back the enum in the Err case of the result
sourcepub fn as_map_mut(&mut self) -> Option<&mut InnerMapSet>
pub fn as_map_mut(&mut self) -> Option<&mut InnerMapSet>
Optionally returns mutable references to the inner fields if this is a InnerContent::Map, otherwise None
sourcepub fn as_map(&self) -> Option<&InnerMapSet>
pub fn as_map(&self) -> Option<&InnerMapSet>
Optionally returns references to the inner fields if this is a InnerContent::Map, otherwise None
sourcepub fn into_map(self) -> Result<InnerMapSet, Self>
pub fn into_map(self) -> Result<InnerMapSet, Self>
Returns the inner fields if this is a InnerContent::Map, otherwise returns back the enum in the Err case of the result
sourcepub fn as_tree_mut(&mut self) -> Option<&mut TreeOp>
pub fn as_tree_mut(&mut self) -> Option<&mut TreeOp>
Optionally returns mutable references to the inner fields if this is a InnerContent::Tree, otherwise None
Trait Implementations§
source§impl Clone for InnerContent
impl Clone for InnerContent
source§fn clone(&self) -> InnerContent
fn clone(&self) -> InnerContent
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for InnerContent
impl Debug for InnerContent
source§impl HasLength for InnerContent
impl HasLength for InnerContent
source§fn content_len(&self) -> usize
fn content_len(&self) -> usize
It is the length of the content, i.e. the length when no Mergable::merge ever happen. Read more
source§impl Mergable for InnerContent
impl Mergable for InnerContent
Auto Trait Implementations§
impl RefUnwindSafe for InnerContent
impl Send for InnerContent
impl Sync for InnerContent
impl Unpin for InnerContent
impl UnwindSafe for InnerContent
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