Struct substreams::pb::substreams::module::KindStore
source · pub struct KindStore {
pub update_policy: i32,
pub value_type: String,
}
Fields§
§update_policy: i32
The update_policy
determines the functions available to mutate the store
(like set()
, set_if_not_exists()
or sum()
, etc..) in
order to ensure that parallel operations are possible and deterministic
Say a store cumulates keys from block 0 to 1M, and a second store cumulates keys from block 1M to 2M. When we want to use this store as a dependency for a downstream module, we will merge the two stores according to this policy.
value_type: String
Implementations§
source§impl KindStore
impl KindStore
sourcepub fn update_policy(&self) -> UpdatePolicy
pub fn update_policy(&self) -> UpdatePolicy
Returns the enum value of update_policy
, or the default if the field is set to an invalid enum value.
sourcepub fn set_update_policy(&mut self, value: UpdatePolicy)
pub fn set_update_policy(&mut self, value: UpdatePolicy)
Sets update_policy
to the provided enum value.
Trait Implementations§
source§impl Message for KindStore
impl Message for KindStore
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Encodes the message to a buffer. Read more
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
Encodes the message to a newly allocated buffer.
source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Encodes the message with a length-delimiter to a buffer. Read more
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Decodes an instance of the message from a buffer. Read more
source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Decodes a length-delimited instance of the message from the buffer.
source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
Decodes an instance of the message from a buffer, and merges it into
self
. Read moresource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
Decodes a length-delimited instance of the message from buffer, and
merges it into
self
.source§impl PartialEq for KindStore
impl PartialEq for KindStore
impl StructuralPartialEq for KindStore
Auto Trait Implementations§
impl Freeze for KindStore
impl RefUnwindSafe for KindStore
impl Send for KindStore
impl Sync for KindStore
impl Unpin for KindStore
impl UnwindSafe for KindStore
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)