Check if the database contains saved catalog data
(
&self,
driver: &dyn StorageDriver<Tree = Box<dyn StorageTree>>,
)
| 260 | |
| 261 | /// Check if the database contains saved catalog data |
| 262 | pub fn has_catalog_data( |
| 263 | &self, |
| 264 | driver: &dyn StorageDriver<Tree = Box<dyn StorageTree>>, |
| 265 | ) -> Result<bool, Box<dyn std::error::Error>> { |
| 266 | let catalog_tree = driver.open_tree("catalog")?; |
| 267 | catalog_tree |
| 268 | .contains_key(b"catalog_data") |
| 269 | .map_err(|e| e.into()) |
| 270 | } |
| 271 | |
| 272 | /// Clear all data from the database |
| 273 | pub fn clear( |
nothing calls this directly
no test coverage detected