pub struct CKB2021Builder {
    pub rfc_0028: Option<EpochNumber>,
    pub rfc_0029: Option<EpochNumber>,
    pub rfc_0030: Option<EpochNumber>,
    pub rfc_0031: Option<EpochNumber>,
    pub rfc_0032: Option<EpochNumber>,
    pub rfc_0036: Option<EpochNumber>,
    pub rfc_0038: Option<EpochNumber>,
}
Expand description

Builder for CKB2021.

Fields§

§rfc_0028: Option<EpochNumber>

Use input cell committing block timestamp as the start time for the relative timestamp in since.

Ref: CKB RFC 0028

§rfc_0029: Option<EpochNumber>

Allow Multiple Cell Dep Matches When There Is No Ambiguity.

Ref: CKB RFC 0029

§rfc_0030: Option<EpochNumber>

Ensure That Index Is Less Than Length In the Input Since Field Using Epoch With Fraction.

Ref: CKB RFC 0030

§rfc_0031: Option<EpochNumber>

Add a variable length field in the block: reuse uncles_hash in the header as extra_hash.

Ref: CKB RFC 0031

§rfc_0032: Option<EpochNumber>

CKB VM Version Selection.

This feature include 4 parts:

  • CKB VM Version Selection.
  • CKB VM version 1.
  • CKB VM Syscalls 2.
  • P2P protocol upgrade.

Ref:

§rfc_0036: Option<EpochNumber>

Remove Header Deps Immature Rule.

Ref: CKB RFC 0036

§rfc_0038: Option<EpochNumber>

Disallow over the max dep expansion limit.

Ref: CKB RFC 0038

Implementations§

source§

impl CKB2021Builder

source

pub fn rfc_0028(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0028.

source

pub fn disable_rfc_0028(self) -> Self

Never enable the RFC PR 0028.

source§

impl CKB2021Builder

source

pub fn rfc_0029(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0029.

source

pub fn disable_rfc_0029(self) -> Self

Never enable the RFC PR 0029.

source§

impl CKB2021Builder

source

pub fn rfc_0030(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0030.

source

pub fn disable_rfc_0030(self) -> Self

Never enable the RFC PR 0030.

source§

impl CKB2021Builder

source

pub fn rfc_0031(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0031.

source

pub fn disable_rfc_0031(self) -> Self

Never enable the RFC PR 0031.

source§

impl CKB2021Builder

source

pub fn rfc_0032(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0032.

source

pub fn disable_rfc_0032(self) -> Self

Never enable the RFC PR 0032.

source§

impl CKB2021Builder

source

pub fn rfc_0036(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0036.

source

pub fn disable_rfc_0036(self) -> Self

Never enable the RFC PR 0036.

source§

impl CKB2021Builder

source

pub fn rfc_0038(self, epoch_number: EpochNumber) -> Self

Set the first epoch number of the RFC PR 0038.

source

pub fn disable_rfc_0038(self) -> Self

Never enable the RFC PR 0038.

source§

impl CKB2021Builder

source

pub fn build(self) -> Result<CKB2021, String>

Build a new CKB2021.

Returns an error if failed at any check, for example, there maybe are some features depend on others.

Trait Implementations§

source§

impl Clone for CKB2021Builder

source§

fn clone(&self) -> CKB2021Builder

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for CKB2021Builder

source§

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

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

impl Default for CKB2021Builder

source§

fn default() -> CKB2021Builder

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

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> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
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