Struct miden_core::Kernel
source · pub struct Kernel(_);
Expand description
A list of procedure hashes defining a VM kernel.
The internally-stored list always has a consistent order, regardless of the order of procedure list used to instantiate a kernel.
Implementations§
source§impl Kernel
impl Kernel
sourcepub fn new(proc_hashes: &[Digest]) -> Self
pub fn new(proc_hashes: &[Digest]) -> Self
Returns a new Kernel instantiated with the specified procedure hashes.
sourcepub fn contains_proc(&self, proc_hash: Digest) -> bool
pub fn contains_proc(&self, proc_hash: Digest) -> bool
Returns true if a procedure with the specified hash belongs to this kernel.
sourcepub fn proc_hashes(&self) -> &[Digest]
pub fn proc_hashes(&self) -> &[Digest]
Returns a list of procedure hashes contained in this kernel.
Trait Implementations§
source§impl PartialEq<Kernel> for Kernel
impl PartialEq<Kernel> for Kernel
source§impl Serializable for Kernel
impl Serializable for Kernel
source§fn write_into<W: ByteWriter>(&self, target: &mut W)
fn write_into<W: ByteWriter>(&self, target: &mut W)
Serializes
self
into bytes and writes these bytes into the target
.source§fn write_batch_into<W>(source: &[Self], target: &mut W)where
W: ByteWriter,
fn write_batch_into<W>(source: &[Self], target: &mut W)where W: ByteWriter,
source§fn get_size_hint(&self) -> usize
fn get_size_hint(&self) -> usize
Returns an estimate of how many bytes are needed to represent self. Read more