Clearing old transactions
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
|
||||
use std::hash::Hash;
|
||||
use std::collections::HashMap;
|
||||
use std::collections::hash_map::Keys;
|
||||
|
||||
/// Structure to hold double-indexed values
|
||||
///
|
||||
@@ -41,6 +42,11 @@ impl<Row, Col, Val> Table<Row, Col, Val>
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns keys iterator for this Table.
|
||||
pub fn keys(&self) -> Keys<Row, HashMap<Col, Val>> {
|
||||
self.map.keys()
|
||||
}
|
||||
|
||||
/// Removes all elements from this Table
|
||||
pub fn clear(&mut self) {
|
||||
self.map.clear();
|
||||
|
||||
Reference in New Issue
Block a user