pub struct EventsBlocksResponse {
pub max_sequence: i64,
pub events: Vec<BlockEvent>,
}
Expand description
EventsBlocksResponse : EventsBlocksResponse contains an ordered collection of BlockEvents and the max retrievable sequence.
Fields§
§max_sequence: i64
max_sequence is the maximum available sequence number to fetch.
events: Vec<BlockEvent>
events is an array of BlockEvents indicating the order to add and remove blocks to maintain a canonical view of blockchain state. Lightweight clients can use this event stream to update state without implementing their own block syncing logic.
Implementations§
source§impl EventsBlocksResponse
impl EventsBlocksResponse
sourcepub fn new(max_sequence: i64, events: Vec<BlockEvent>) -> EventsBlocksResponse
pub fn new(max_sequence: i64, events: Vec<BlockEvent>) -> EventsBlocksResponse
EventsBlocksResponse contains an ordered collection of BlockEvents and the max retrievable sequence.
Trait Implementations§
source§impl Clone for EventsBlocksResponse
impl Clone for EventsBlocksResponse
source§fn clone(&self) -> EventsBlocksResponse
fn clone(&self) -> EventsBlocksResponse
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for EventsBlocksResponse
impl Debug for EventsBlocksResponse
source§impl Default for EventsBlocksResponse
impl Default for EventsBlocksResponse
source§fn default() -> EventsBlocksResponse
fn default() -> EventsBlocksResponse
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for EventsBlocksResponse
impl<'de> Deserialize<'de> for EventsBlocksResponse
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq<EventsBlocksResponse> for EventsBlocksResponse
impl PartialEq<EventsBlocksResponse> for EventsBlocksResponse
source§fn eq(&self, other: &EventsBlocksResponse) -> bool
fn eq(&self, other: &EventsBlocksResponse) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for EventsBlocksResponse
impl Serialize for EventsBlocksResponse
impl Eq for EventsBlocksResponse
impl StructuralEq for EventsBlocksResponse
impl StructuralPartialEq for EventsBlocksResponse
Auto Trait Implementations§
impl RefUnwindSafe for EventsBlocksResponse
impl Send for EventsBlocksResponse
impl Sync for EventsBlocksResponse
impl Unpin for EventsBlocksResponse
impl UnwindSafe for EventsBlocksResponse
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