Struct brb_dt_tree::BRBTree[][src]

pub struct BRBTree<A: Clone + Hash + Ord + Debug, ID: TreeId, M: TreeMeta> { /* fields omitted */ }

A BRBDataType wrapper around crdt_tree::State

Implementations

impl<A: Clone + Hash + Ord + Debug, ID: TreeId, M: TreeMeta> BRBTree<A, ID, M>[src]

pub fn opmove(&self, parent: ID, meta: M, child: ID) -> OpMove<ID, M, A>[src]

generates a move operation. (crdt_tree::OpMove)

pub fn actor(&self) -> &A[src]

returns the actor

pub fn treestate(&self) -> &State<ID, M, A>[src]

returns underlying crdt_tree::State object

pub fn treereplica(&self) -> &TreeReplica<ID, M, A>[src]

returns underlying crdt_tree::State object

Trait Implementations

impl<A: Hash + Ord + Clone + Debug + Serialize + 'static, ID: TreeId + Debug + Serialize, M: TreeMeta + Eq + Debug + Hash + Serialize> BRBDataType<A> for BRBTree<A, ID, M>[src]

type Op = OpMove<ID, M, A>

The set of ops this data type accepts

type ValidationError = ValidationError

A validation error specific to this data type.

fn new(actor: A) -> Self[src]

Create a new BRBTree

fn validate(
    &self,
    source: &A,
    op: &Self::Op
) -> Result<(), Self::ValidationError>
[src]

Validate an operation.

fn apply(&mut self, op: Self::Op)[src]

Apply an operation to the underlying Tree datatype

impl<A: Clone + Hash + Ord + Debug, ID: Clone + TreeId, M: Clone + TreeMeta> Clone for BRBTree<A, ID, M>[src]

impl<A: Debug + Clone + Hash + Ord, ID: Debug + TreeId, M: Debug + TreeMeta> Debug for BRBTree<A, ID, M>[src]

impl<A: Eq + Clone + Hash + Ord + Debug, ID: Eq + TreeId, M: Eq + TreeMeta> Eq for BRBTree<A, ID, M>[src]

impl<A: PartialEq + Clone + Hash + Ord + Debug, ID: PartialEq + TreeId, M: PartialEq + TreeMeta> PartialEq<BRBTree<A, ID, M>> for BRBTree<A, ID, M>[src]

impl<A: Clone + Hash + Ord + Debug, ID: TreeId, M: TreeMeta> Serialize for BRBTree<A, ID, M> where
    A: Serialize,
    ID: Serialize,
    M: Serialize
[src]

impl<A: Clone + Hash + Ord + Debug, ID: TreeId, M: TreeMeta> StructuralEq for BRBTree<A, ID, M>[src]

impl<A: Clone + Hash + Ord + Debug, ID: TreeId, M: TreeMeta> StructuralPartialEq for BRBTree<A, ID, M>[src]

Auto Trait Implementations

impl<A, ID, M> RefUnwindSafe for BRBTree<A, ID, M> where
    A: RefUnwindSafe,
    ID: RefUnwindSafe,
    M: RefUnwindSafe

impl<A, ID, M> Send for BRBTree<A, ID, M> where
    A: Send,
    ID: Send,
    M: Send

impl<A, ID, M> Sync for BRBTree<A, ID, M> where
    A: Sync,
    ID: Sync,
    M: Sync

impl<A, ID, M> Unpin for BRBTree<A, ID, M> where
    A: Unpin,
    ID: Unpin,
    M: Unpin

impl<A, ID, M> UnwindSafe for BRBTree<A, ID, M> where
    A: UnwindSafe,
    ID: UnwindSafe,
    M: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BRBDT for T where
    T: BRBDataType<Actor>, 
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<TM> TreeMeta for TM where
    TM: Clone
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,