Skip to content

Commit

Permalink
persistence: add convenience Stock::in_memory method
Browse files Browse the repository at this point in the history
  • Loading branch information
dr-orlovsky committed Jun 30, 2024
1 parent e90d205 commit 50fd6f4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/persistence/stock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -366,6 +366,10 @@ where
}
}

impl Stock {
pub fn in_memory() -> Self { Self::default() }
}

impl<S: StashProvider, H: StateProvider, P: IndexProvider> Stock<S, H, P> {
pub fn with(stash_provider: S, state_provider: H, index_provider: P) -> Self {
Stock {
Expand Down

0 comments on commit 50fd6f4

Please sign in to comment.