pub enum PickleDbDumpPolicy {
NeverDump,
AutoDump,
DumpUponRequest,
PeriodicDump(Duration),
}
An enum that determines the policy of dumping PickleDB changes into the file
Never dump any change, file will always remain read-only
Every change will be dumped immediately and automatically to the file
Data won't be dumped unless the user calls PickleDB::dump() proactively to dump the data
Changes will be dumped to the file periodically, no sooner than the Duration provided by the user.
The way this mechanism works is as follows: each time there is a DB change the last DB dump time is checked.
If the time that has passed since the last dump is higher than Duration, changes will be dumped,
otherwise changes will not be dumped
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Mutably borrows from an owned value. Read more