pub struct SuperRoot {
pub timestamp: u64,
pub output_roots: Vec<OutputRootWithChain>,
}Expand description
The SuperRoot is the snapshot of the superchain at a given timestamp.
Fields§
§timestamp: u64The timestamp of the superchain snapshot, in seconds.
output_roots: Vec<OutputRootWithChain>The chain IDs and output root commitments of all chains within the dependency set.
Implementations§
Source§impl SuperRoot
impl SuperRoot
Sourcepub fn new(timestamp: u64, output_roots: Vec<OutputRootWithChain>) -> Self
pub fn new(timestamp: u64, output_roots: Vec<OutputRootWithChain>) -> Self
Create a new SuperRoot with the given timestamp and output roots.
Sourcepub fn decode(buf: &mut &[u8]) -> SuperRootResult<Self>
pub fn decode(buf: &mut &[u8]) -> SuperRootResult<Self>
Decodes a SuperRoot from the given buffer.
Sourcepub fn encoded_length(&self) -> usize
pub fn encoded_length(&self) -> usize
Returns the encoded length of the SuperRoot.
Trait Implementations§
impl Eq for SuperRoot
impl StructuralPartialEq for SuperRoot
Auto Trait Implementations§
impl Freeze for SuperRoot
impl RefUnwindSafe for SuperRoot
impl Send for SuperRoot
impl Sync for SuperRoot
impl Unpin for SuperRoot
impl UnwindSafe for SuperRoot
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