Struct ckb_types::core::BlockReward

source ·
pub struct BlockReward {
    pub total: Capacity,
    pub primary: Capacity,
    pub secondary: Capacity,
    pub tx_fee: Capacity,
    pub proposal_reward: Capacity,
}
Expand description

Fields§

§total: Capacity

The total block reward.

§primary: Capacity

The primary block reward.

§secondary: Capacity

The secondary block reward.

Notice

  • A part of the secondary issuance goes to the miners, the ratio depends on how many CKB are used to store state.
  • And a part of the secondary issuance goes to the NervosDAO, the ratio depends on how many CKB are deposited and locked in the NervosDAO.
  • The rest of the secondary issuance is determined by the community through the governance mechanism. Before the community can reach agreement, this part of the secondary issuance is going to be burned.
§tx_fee: Capacity

The transaction fees that are rewarded to miners because the transaction is committed in the block.

Notice

Miners only get 60% of the transaction fee for each transaction committed in the block.

§proposal_reward: Capacity

The transaction fees that are rewarded to miners because the transaction is proposed in the block or its uncles.

Notice

Miners only get 40% of the transaction fee for each transaction proposed in the block and committed later in its active commit window.

Trait Implementations§

source§

impl Debug for BlockReward

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for BlockReward

source§

fn default() -> BlockReward

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

impl From<BlockReward> for MinerReward

source§

fn from(reward: BlockReward) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

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

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

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

Performs the conversion.
§

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

§

fn vzip(self) -> V