Skip to main content

TransactionCommand

Trait TransactionCommand 

Source
pub trait TransactionCommand: Send + Sync {
    // Required methods
    fn name(&self) -> &str;
    fn args(&self) -> Vec<RespValue>;
    fn key(&self) -> Option<String>;
}
Expand description

Trait for commands that can be used in transactions

Required Methods§

Source

fn name(&self) -> &str

Get the command name

Source

fn args(&self) -> Vec<RespValue>

Get the command arguments

Source

fn key(&self) -> Option<String>

Get the key(s) involved in this command (for WATCH)

Implementors§