[][src]Enum taskchampion::taskstorage::Operation

pub enum Operation {
    Create {
        uuid: Uuid,
    },
    Delete {
        uuid: Uuid,
    },
    Update {
        uuid: Uuid,
        property: String,
        value: Option<String>,
        timestamp: DateTime<Utc>,
    },
}

An Operation defines a single change to the task database

Variants

Create

Create a new task.

On application, if the task already exists, the operation does nothing.

Fields of Create

uuid: Uuid
Delete

Delete an existing task.

On application, if the task does not exist, the operation does nothing.

Fields of Delete

uuid: Uuid
Update

Update an existing task, setting the given property to the given value. If the value is None, then the corresponding property is deleted.

If the given task does not exist, the operation does nothing.

Fields of Update

uuid: Uuidproperty: Stringvalue: Option<String>timestamp: DateTime<Utc>

Implementations

impl Operation[src]

pub fn transform(
    operation1: Operation,
    operation2: Operation
) -> (Option<Operation>, Option<Operation>)
[src]

Trait Implementations

impl Clone for Operation[src]

impl Debug for Operation[src]

impl<'de> Deserialize<'de> for Operation[src]

impl PartialEq<Operation> for Operation[src]

impl Serialize for Operation[src]

impl StructuralPartialEq for Operation[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

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

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

type Owned = T

The resulting type after obtaining ownership.

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>,