Struct EnvironmentSpecBuilder

Source
pub struct EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,
{ /* private fields */ }
Expand description

An environment specification builder.

Implementations§

Source§

impl<F, B, H, T, BN, NTER, BS> EnvironmentSpecBuilder<F, Missing<AccountId>, B, H, T, BN, NTER, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn account_id( self, account_id: TypeSpec<F>, ) -> EnvironmentSpecBuilder<F, AccountId, B, H, T, BN, NTER, BS>

Sets the AccountId type of the environment.

Source§

impl<F, A, H, T, BN, NTER, BS> EnvironmentSpecBuilder<F, A, Missing<Balance>, H, T, BN, NTER, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn balance( self, balance: TypeSpec<F>, ) -> EnvironmentSpecBuilder<F, A, Balance, H, T, BN, NTER, BS>

Sets the Balance type of the environment.

Source§

impl<F, A, B, T, BN, NTER, BS> EnvironmentSpecBuilder<F, A, B, Missing<Hash>, T, BN, NTER, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn hash( self, hash: TypeSpec<F>, ) -> EnvironmentSpecBuilder<F, A, B, Hash, T, BN, NTER, BS>

Sets the Hash type of the environment.

Source§

impl<F, A, B, H, BN, NTER, BS> EnvironmentSpecBuilder<F, A, B, H, Missing<Timestamp>, BN, NTER, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn timestamp( self, timestamp: TypeSpec<F>, ) -> EnvironmentSpecBuilder<F, A, B, H, Timestamp, BN, NTER, BS>

Sets the Timestamp type of the environment.

Source§

impl<F, A, B, H, T, NTER, BS> EnvironmentSpecBuilder<F, A, B, H, T, Missing<BlockNumber>, NTER, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn block_number( self, block_number: TypeSpec<F>, ) -> EnvironmentSpecBuilder<F, A, B, H, T, BlockNumber, NTER, BS>

Sets the BlockNumber type of the environment.

Source§

impl<F, A, B, H, T, BN, BS> EnvironmentSpecBuilder<F, A, B, H, T, BN, Missing<NativeToEthRatio>, BS>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn native_to_eth_ratio( self, native_to_eth_ratio: u32, ) -> EnvironmentSpecBuilder<F, A, B, H, T, BN, NativeToEthRatio, BS>

Sets the NATIVE_TO_ETH_RATIO value of the environment.

Source§

impl<F, A, B, H, T, BN, NTER> EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, Missing<BufferSize>>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn static_buffer_size( self, static_buffer_size: usize, ) -> EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BufferSize>

Sets the size of the static buffer configured via environment variable.`

Source§

impl<F> EnvironmentSpecBuilder<F, AccountId, Balance, Hash, Timestamp, BlockNumber, NativeToEthRatio, BufferSize>
where F: Form, TypeSpec<F>: Default, EnvironmentSpec<F>: Default,

Source

pub fn done(self) -> EnvironmentSpec<F>

Finished constructing the EnvironmentSpec object.

Auto Trait Implementations§

§

impl<F, A, B, H, T, BN, NTER, BS> Freeze for EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where EnvironmentSpec<F>: Sized, TypeSpec<F>: Sized, <F as Form>::Type: Freeze,

§

impl<F, A, B, H, T, BN, NTER, BS> RefUnwindSafe for EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where EnvironmentSpec<F>: Sized, TypeSpec<F>: Sized, <F as Form>::Type: RefUnwindSafe, <F as Form>::String: RefUnwindSafe,

§

impl<F, A, B, H, T, BN, NTER, BS> Send for EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where EnvironmentSpec<F>: Sized, TypeSpec<F>: Sized, <F as Form>::Type: Send, <F as Form>::String: Send,

§

impl<F, A, B, H, T, BN, NTER, BS> Sync for EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where EnvironmentSpec<F>: Sized, TypeSpec<F>: Sized, <F as Form>::Type: Sync, <F as Form>::String: Sync,

§

impl<F, A, B, H, T, BN, NTER, BS> Unpin for EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where EnvironmentSpec<F>: Sized, TypeSpec<F>: Sized, <F as Form>::Type: Unpin, <F as Form>::String: Unpin,

§

impl<F, A, B, H, T, BN, NTER, BS> UnwindSafe for EnvironmentSpecBuilder<F, A, B, H, T, BN, NTER, BS>
where EnvironmentSpec<F>: Sized, TypeSpec<F>: Sized, <F as Form>::Type: UnwindSafe, <F as Form>::String: UnwindSafe,

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where 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.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where 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> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
§

impl<T, Outer> IsWrappedBy<Outer> for T
where Outer: AsRef<T> + AsMut<T> + From<T>, T: From<Outer>,

§

fn from_ref(outer: &Outer) -> &T

Get a reference to the inner from the outer.

§

fn from_mut(outer: &mut Outer) -> &mut T

Get a mutable reference to the inner from the outer.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
§

impl<T> SaturatedConversion for T

§

fn saturated_from<T>(t: T) -> Self
where Self: UniqueSaturatedFrom<T>,

Convert from a value of T into an equivalent instance of Self. Read more
§

fn saturated_into<T>(self) -> T
where Self: UniqueSaturatedInto<T>,

Consume self to return an equivalent value of T. Read more
Source§

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

Source§

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 T
where U: TryFrom<T>,

Source§

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<S, T> UncheckedInto<T> for S
where T: UncheckedFrom<S>,

§

fn unchecked_into(self) -> T

The counterpart to unchecked_from.
§

impl<T, S> UniqueSaturatedInto<T> for S
where T: Bounded, S: TryInto<T>,

§

fn unique_saturated_into(self) -> T

Consume self to return an equivalent value of T.
§

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

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more