Enum crdts::list::Op [−][src]
pub enum Op<T, A: Ord> { Insert { id: Identifier<OrdDot<A>>, val: T, }, Delete { id: Identifier<OrdDot<A>>, dot: Dot<A>, }, }
Operations that can be performed on a List
Variants
Insert an element
Fields of Insert
Delete an element
Fields of Delete
id: Identifier<OrdDot<A>>
The Identifier of the insertion we’re removing
dot: Dot<A>
id of site that issued delete
Implementations
impl<T, A: Ord + Clone + Eq> Op<T, A>
[src]
pub fn id(&self) -> &Identifier<OrdDot<A>>
[src]
Returns the Identifier this operation is concerning.
pub fn dot(&self) -> Dot<A>
[src]
Return the Dot originating the operation.
Trait Implementations
impl<T: Clone, A: Clone + Ord> Clone for Op<T, A>
[src]
impl<T: Debug, A: Debug + Ord> Debug for Op<T, A>
[src]
impl<'de, T, A: Ord> Deserialize<'de> for Op<T, A> where
T: Deserialize<'de>,
A: Deserialize<'de>,
[src]
T: Deserialize<'de>,
A: Deserialize<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl<T: Eq, A: Eq + Ord> Eq for Op<T, A>
[src]
impl<T: PartialEq, A: PartialEq + Ord> PartialEq<Op<T, A>> for Op<T, A>
[src]
impl<T, A: Ord> Serialize for Op<T, A> where
T: Serialize,
A: Serialize,
[src]
T: Serialize,
A: Serialize,
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<T, A: Ord> StructuralEq for Op<T, A>
[src]
impl<T, A: Ord> StructuralPartialEq for Op<T, A>
[src]
Auto Trait Implementations
impl<T, A> RefUnwindSafe for Op<T, A> where
A: RefUnwindSafe,
T: RefUnwindSafe,
A: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, A> Send for Op<T, A> where
A: Send,
T: Send,
A: Send,
T: Send,
impl<T, A> Sync for Op<T, A> where
A: Sync,
T: Sync,
A: Sync,
T: Sync,
impl<T, A> Unpin for Op<T, A> where
A: Unpin,
T: Unpin,
A: Unpin,
T: Unpin,
impl<T, A> UnwindSafe for Op<T, A> where
A: UnwindSafe,
T: UnwindSafe,
A: UnwindSafe,
T: UnwindSafe,
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> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,