toasty_core/driver/
operation.rs

1mod delete_by_key;
2pub use delete_by_key::DeleteByKey;
3
4mod find_pk_by_index;
5pub use find_pk_by_index::FindPkByIndex;
6
7mod get_by_key;
8pub use get_by_key::GetByKey;
9
10mod insert;
11pub use insert::Insert;
12
13mod query_pk;
14pub use query_pk::QueryPk;
15
16mod query_sql;
17pub use query_sql::QuerySql;
18
19mod transaction;
20pub use transaction::{IsolationLevel, Transaction};
21
22mod update_by_key;
23pub use update_by_key::UpdateByKey;
24
25#[derive(Debug, Clone)]
26pub enum Operation {
27    /// Create a new record. This will always be a lowered `stmt::Insert`
28    Insert(Insert),
29
30    /// Delete records identified by the given keys.
31    DeleteByKey(DeleteByKey),
32
33    /// Find by index
34    FindPkByIndex(FindPkByIndex),
35
36    /// Get one or more records by the primary key
37    GetByKey(GetByKey),
38
39    /// Query the table, filtering by the primary key
40    QueryPk(QueryPk),
41
42    /// Execute a SQL query
43    QuerySql(QuerySql),
44
45    /// Execute a transaction lifecycle op
46    Transaction(Transaction),
47
48    /// Update a record by the primary key
49    UpdateByKey(UpdateByKey),
50}