rsdbc_sqlite/options/
journal_mode.rs1#[derive(Debug, Clone)]
4pub enum SqliteJournalMode {
5 Delete,
6 Truncate,
7 Persist,
8 Memory,
9 Wal,
10 Off,
11}
12
13impl SqliteJournalMode {
15 pub(crate) fn as_str(&self) -> &'static str {
16 match self {
17 SqliteJournalMode::Delete => "DELETE",
18 SqliteJournalMode::Truncate => "TRUNCATE",
19 SqliteJournalMode::Persist => "PERSIST",
20 SqliteJournalMode::Memory => "MEMORY",
21 SqliteJournalMode::Wal => "WAL",
22 SqliteJournalMode::Off => "OFF",
23 }
24 }
25}
26
27impl Default for SqliteJournalMode {
28 fn default() -> Self {
29 SqliteJournalMode::Wal
30 }
31}