Trait optra::Operation [] [src]

pub trait Operation: Debug + Clone {
    fn get_position(&self) -> u64;
    fn get_increment(&self) -> i64;
    fn get_timestamp(&self) -> u32;
    fn set_timestamp(&mut self, new_timestamp: u32);
}

An operation that will make a change to a file.

Required Methods

Gets the position this operation will be perfomed at

Gets the size change this operation will perform. For insert operations, it's the length of the data they will insert. For delete operations, it's the length of the data they will delete

Gets the current local timestamp of this operation

Sets the local timestamp of this operation

Implementors