pub trait LogClient<'a, T: Serialize + Deserialize<'a>, TL: TransparentLog<'a, T>> {
// Required methods
fn latest(&self) -> &LogTree<TL::LogSize>;
fn set_latest(&mut self, latest: LogTree<TL::LogSize>);
fn cached(&self, position: &LogTreePosition<TL::LogSize>) -> Option<String>;
fn add_cached(
&mut self,
proofs: &HashMap<LogTreePosition<TL::LogSize>, String>,
);
}Expand description
A simple log client, optionally keeping a cache of tree entries
Required Methods§
Sourcefn set_latest(&mut self, latest: LogTree<TL::LogSize>)
fn set_latest(&mut self, latest: LogTree<TL::LogSize>)
Set the latest tree information
Sourcefn cached(&self, position: &LogTreePosition<TL::LogSize>) -> Option<String>
fn cached(&self, position: &LogTreePosition<TL::LogSize>) -> Option<String>
Get a cached position if known
Sourcefn add_cached(&mut self, proofs: &HashMap<LogTreePosition<TL::LogSize>, String>)
fn add_cached(&mut self, proofs: &HashMap<LogTreePosition<TL::LogSize>, String>)
Cache all positions in the HashMap