Insert a change, computing its hash automatically. # Arguments `change` - The change to store # Returns The computed hash. # Errors Returns an error if hash computation fails.
(&self, change: Change)
| 374 | /// |
| 375 | /// Returns an error if hash computation fails. |
| 376 | pub fn insert_change(&self, change: Change) -> Result<Hash, ChangeError> { |
| 377 | let hash = change.hash()?; |
| 378 | self.insert(hash, change); |
| 379 | Ok(hash) |
| 380 | } |
| 381 | |
| 382 | /// Remove a change from the store. |
| 383 | /// |