Struct casper_execution_engine::core::engine_state::genesis::GenesisConfig
source · pub struct GenesisConfig { /* private fields */ }
Expand description
Represents a configuration of a genesis process.
Implementations§
source§impl GenesisConfig
impl GenesisConfig
sourcepub fn new(
name: String,
timestamp: u64,
protocol_version: ProtocolVersion,
ee_config: ExecConfig
) -> Self
pub fn new( name: String, timestamp: u64, protocol_version: ProtocolVersion, ee_config: ExecConfig ) -> Self
Creates a new genesis config object.
sourcepub fn protocol_version(&self) -> ProtocolVersion
pub fn protocol_version(&self) -> ProtocolVersion
Returns protocol version.
sourcepub fn ee_config(&self) -> &ExecConfig
pub fn ee_config(&self) -> &ExecConfig
Returns configuration details of the genesis process.
sourcepub fn ee_config_mut(&mut self) -> &mut ExecConfig
pub fn ee_config_mut(&mut self) -> &mut ExecConfig
Returns mutable reference to the configuration.
sourcepub fn take_ee_config(self) -> ExecConfig
pub fn take_ee_config(self) -> ExecConfig
Returns genesis configuration and consumes the object.
Trait Implementations§
source§impl Clone for GenesisConfig
impl Clone for GenesisConfig
source§fn clone(&self) -> GenesisConfig
fn clone(&self) -> GenesisConfig
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 GenesisConfig
impl Debug for GenesisConfig
source§impl Distribution<GenesisConfig> for Standard
impl Distribution<GenesisConfig> for Standard
source§fn sample<R: Rng + ?Sized>(&self, rng: &mut R) -> GenesisConfig
fn sample<R: Rng + ?Sized>(&self, rng: &mut R) -> GenesisConfig
Generate a random value of
T
, using rng
as the source of randomness.source§fn sample_iter<R>(self, rng: R) -> DistIter<Self, R, T>
fn sample_iter<R>(self, rng: R) -> DistIter<Self, R, T>
Create an iterator that generates random values of
T
, using rng
as
the source of randomness. Read moresource§impl PartialEq for GenesisConfig
impl PartialEq for GenesisConfig
source§fn eq(&self, other: &GenesisConfig) -> bool
fn eq(&self, other: &GenesisConfig) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for GenesisConfig
impl StructuralPartialEq for GenesisConfig
Auto Trait Implementations§
impl RefUnwindSafe for GenesisConfig
impl Send for GenesisConfig
impl Sync for GenesisConfig
impl Unpin for GenesisConfig
impl UnwindSafe for GenesisConfig
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.