pub struct TlogEntryBuilder { /* private fields */ }Expand description
Helper to create a transparency log entry
Implementations§
Source§impl TlogEntryBuilder
impl TlogEntryBuilder
Sourcepub fn from_log_entry(entry: &LogEntry, kind: &str, version: &str) -> Self
pub fn from_log_entry(entry: &LogEntry, kind: &str, version: &str) -> Self
Create a tlog entry builder from a Rekor LogEntry response
This method extracts all relevant fields from a Rekor API response and populates the builder automatically.
§Arguments
entry- The LogEntry returned from the Rekor APIkind- The entry kind (e.g., “hashedrekord”, “dsse”)version- The entry version (e.g., “0.0.1”)
Sourcepub fn integrated_time(self, time: u64) -> Self
pub fn integrated_time(self, time: u64) -> Self
Set the integrated time (Unix timestamp)
Sourcepub fn inclusion_promise(self, signed_entry_timestamp: SignedTimestamp) -> Self
pub fn inclusion_promise(self, signed_entry_timestamp: SignedTimestamp) -> Self
Set the inclusion promise (Signed Entry Timestamp)
Sourcepub fn inclusion_proof(
self,
log_index: u64,
root_hash: Sha256Hash,
tree_size: u64,
hashes: Vec<Sha256Hash>,
checkpoint: String,
) -> Self
pub fn inclusion_proof( self, log_index: u64, root_hash: Sha256Hash, tree_size: u64, hashes: Vec<Sha256Hash>, checkpoint: String, ) -> Self
Set the inclusion proof
§Arguments
log_index- The log indexroot_hash- The root hashtree_size- The tree sizehashes- The proof hashescheckpoint- The checkpoint envelope
Sourcepub fn build(self) -> TransparencyLogEntry
pub fn build(self) -> TransparencyLogEntry
Build the transparency log entry
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TlogEntryBuilder
impl RefUnwindSafe for TlogEntryBuilder
impl Send for TlogEntryBuilder
impl Sync for TlogEntryBuilder
impl Unpin for TlogEntryBuilder
impl UnwindSafe for TlogEntryBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more