Struct ics23::InnerSpec [−][src]
pub struct InnerSpec {
pub child_order: Vec<i32>,
pub child_size: i32,
pub min_prefix_length: i32,
pub max_prefix_length: i32,
pub empty_child: Vec<u8>,
pub hash: i32,
}
Expand description
InnerSpec contains all store-specific structure info to determine if two proofs from a given store are neighbors.
This enables:
isLeftMost(spec: InnerSpec, op: InnerOp) isRightMost(spec: InnerSpec, op: InnerOp) isLeftNeighbor(spec: InnerSpec, left: InnerOp, right: InnerOp)
Fields
child_order: Vec<i32>
Child order is the ordering of the children node, must count from 0 iavl tree is [0, 1] (left then right) merk is [0, 2, 1] (left, right, here)
child_size: i32
min_prefix_length: i32
max_prefix_length: i32
empty_child: Vec<u8>
empty child is the prehash image that is used when one child is nil (eg. 20 bytes of 0)
hash: i32
hash is the algorithm that must be used for each InnerOp
Implementations
Trait Implementations
Returns the encoded length of the message without a length delimiter.
Encodes the message to a buffer. Read more
Encodes the message to a newly allocated buffer.
Encodes the message with a length-delimiter to a buffer. Read more
Encodes the message with a length-delimiter to a newly allocated buffer.
Decodes an instance of the message from a buffer. Read more
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
B: Buf,
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Decodes an instance of the message from a buffer, and merges it into self
. Read more
Decodes a length-delimited instance of the message from buffer, and
merges it into self
. Read more
Auto Trait Implementations
impl RefUnwindSafe for InnerSpec
impl UnwindSafe for InnerSpec
Blanket Implementations
Mutably borrows from an owned value. Read more