Struct solana_sdk::genesis_config::GenesisConfig[][src]

pub struct GenesisConfig {
Show fields pub creation_time: UnixTimestamp, pub accounts: BTreeMap<Pubkey, Account>, pub native_instruction_processors: Vec<(String, Pubkey)>, pub rewards_pools: BTreeMap<Pubkey, Account>, pub ticks_per_slot: u64, pub unused: u64, pub poh_config: PohConfig, pub __backwards_compat_with_v0_23: u64, pub fee_rate_governor: FeeRateGovernor, pub rent: Rent, pub inflation: Inflation, pub epoch_schedule: EpochSchedule, pub cluster_type: ClusterType,
}

Fields

creation_time: UnixTimestamp

when the network (bootstrap validator) was started relative to the UNIX Epoch

accounts: BTreeMap<Pubkey, Account>

initial accounts

native_instruction_processors: Vec<(String, Pubkey)>

built-in programs

rewards_pools: BTreeMap<Pubkey, Account>

accounts for network rewards, these do not count towards capitalization

ticks_per_slot: u64unused: u64poh_config: PohConfig

network speed configuration

__backwards_compat_with_v0_23: u64

this field exists only to ensure that the binary layout of GenesisConfig remains compatible with the Solana v0.23 release line

fee_rate_governor: FeeRateGovernor

transaction fee config

rent: Rent

rent config

inflation: Inflation

inflation config

epoch_schedule: EpochSchedule

how slots map to epochs

cluster_type: ClusterType

network runlevel

Implementations

impl GenesisConfig[src]

pub fn new(
    accounts: &[(Pubkey, AccountSharedData)],
    native_instruction_processors: &[(String, Pubkey)]
) -> Self
[src]

pub fn hash(&self) -> Hash[src]

pub fn load(ledger_path: &Path) -> Result<Self, Error>[src]

pub fn write(&self, ledger_path: &Path) -> Result<(), Error>[src]

pub fn add_account(&mut self, pubkey: Pubkey, account: AccountSharedData)[src]

pub fn add_native_instruction_processor(
    &mut self,
    name: String,
    program_id: Pubkey
)
[src]

pub fn hashes_per_tick(&self) -> Option<u64>[src]

pub fn ticks_per_slot(&self) -> u64[src]

pub fn ns_per_slot(&self) -> u128[src]

pub fn slots_per_year(&self) -> f64[src]

Trait Implementations

impl AbiExample for GenesisConfig[src]

fn example() -> Self[src]

impl Clone for GenesisConfig[src]

fn clone(&self) -> GenesisConfig[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for GenesisConfig[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Default for GenesisConfig[src]

fn default() -> Self[src]

Returns the “default value” for a type. Read more

impl<'de> Deserialize<'de> for GenesisConfig[src]

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
    __D: Deserializer<'de>, 
[src]

Deserialize this value from the given Serde deserializer. Read more

impl Display for GenesisConfig[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Serialize for GenesisConfig[src]

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
    __S: Serializer
[src]

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

impl<T> AbiEnumVisitor for T where
    T: Serialize + ?Sized
[src]

pub default fn visit_for_abi(
    &self,
    _digester: &mut AbiDigester
) -> Result<AbiDigester, DigestError>
[src]

impl<T> AbiEnumVisitor for T where
    T: Serialize + AbiExample + ?Sized
[src]

pub default fn visit_for_abi(
    &self,
    digester: &mut AbiDigester
) -> Result<AbiDigester, DigestError>
[src]

impl<T> AbiExample for T[src]

pub default fn example() -> T[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

Creates owned data from borrowed data, usually by cloning. Read more

pub fn clone_into(&self, target: &mut T)[src]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T> ToString for T where
    T: Display + ?Sized
[src]

pub default fn to_string(&self) -> String[src]

Converts the given value to a String. Read more

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

pub fn vzip(self) -> V

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]