pub struct Channel { /* private fields */ }
Expand description
A Channel is a set of batches that are split into at least one, but possibly multiple frames.
Frames are allowed to be ingested out of order.
Each frame is ingested one by one. Once a frame with closed
is added to the channel, the
channel may mark itself as ready for reading once all intervening frames have been added
Implementations§
Source§impl Channel
impl Channel
Sourcepub fn add_frame(
&mut self,
frame: Frame,
l1_inclusion_block: BlockInfo,
) -> Result<(), ChannelError>
pub fn add_frame( &mut self, frame: Frame, l1_inclusion_block: BlockInfo, ) -> Result<(), ChannelError>
Sourcepub const fn open_block_number(&self) -> u64
pub const fn open_block_number(&self) -> u64
Returns the block number of the L1 block that contained the first Frame in this channel.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Channel
impl RefUnwindSafe for Channel
impl Send for Channel
impl Sync for Channel
impl Unpin for Channel
impl UnwindSafe for Channel
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)