Type Alias EmptyArgumentList

Source
pub type EmptyArgumentList<Abi> = ArgumentList<ArgumentListEnd, ArgumentListEnd, Abi>;
Expand description

An empty argument list.

Aliased Type§

struct EmptyArgumentList<Abi> { /* private fields */ }

Implementations§

Source§

impl<Abi> EmptyArgumentList<Abi>

Source

pub fn empty() -> EmptyArgumentList<Abi>

Creates a new empty argument list.

Source

pub fn push_arg<T>(self, arg: T) -> ArgumentList<Argument<T>, Self, Abi>
where T: AbiEncodeWith<Abi>,

Pushes the first argument to the empty argument list.

Trait Implementations§

Source§

impl Encode for EmptyArgumentList<ScaleEncoding>

Source§

fn size_hint(&self) -> usize

If possible give a hint of expected size of the encoding. Read more
Source§

fn encode_to<O: Output + ?Sized>(&self, _output: &mut O)

Convert self to a slice and append it to the destination.
§

fn encode(&self) -> Vec<u8>

Convert self to an owned vector.
§

fn using_encoded<R, F>(&self, f: F) -> R
where F: FnOnce(&[u8]) -> R,

Convert self to a slice and then invoke the given closure with it.
§

fn encoded_size(&self) -> usize

Calculates the encoded size. Read more
Source§

impl SolTypeValue<()> for EmptyArgumentList<SolEncoding>

Source§

fn stv_to_tokens(&self) -> <() as SolType>::Token<'_>

Source§

fn stv_abi_encode_packed_to(&self, _out: &mut Vec<u8>)

Source§

fn stv_eip712_data_word(&self) -> Word

§

fn stv_abi_encoded_size(&self) -> usize

§

fn stv_abi_packed_encoded_size(&self) -> usize

Source§

impl SolValue for EmptyArgumentList<SolEncoding>

Source§

type SolType = ()

The Solidity type that this type corresponds to.
Source§

fn abi_encode(&self) -> Vec<u8>

ABI-encodes the value. Read more
§

fn sol_name(&self) -> &'static str

The name of the associated Solidity type. Read more
§

fn sol_type_name(&self) -> Cow<'static, str>

👎Deprecated since 0.6.3: use sol_name instead
The name of the associated Solidity type. Read more
§

fn tokenize(&self) -> <Self::SolType as SolType>::Token<'_>

Tokenizes the given value into this type’s token. Read more
§

fn detokenize(token: <Self::SolType as SolType>::Token<'_>) -> Self
where Self: From<<Self::SolType as SolType>::RustType>,

Detokenize a value from the given token. Read more
§

fn abi_encoded_size(&self) -> usize

Calculate the ABI-encoded size of the data. Read more
§

fn eip712_data_word(&self) -> FixedBytes<32>

Encode this data according to EIP-712 encodeData rules, and hash it if necessary. Read more
§

fn abi_encode_packed_to(&self, out: &mut Vec<u8>)

Non-standard Packed Mode ABI encoding. Read more
§

fn abi_encode_packed(&self) -> Vec<u8>

Non-standard Packed Mode ABI encoding. Read more
§

fn abi_encode_sequence(&self) -> Vec<u8>
where <Self::SolType as SolType>::Token<'a>: for<'a> TokenSeq<'a>,

Encodes an ABI sequence. Read more
§

fn abi_encode_params(&self) -> Vec<u8>
where <Self::SolType as SolType>::Token<'a>: for<'a> TokenSeq<'a>,

Encodes an ABI sequence suitable for function parameters. Read more
§

fn abi_decode(data: &[u8], validate: bool) -> Result<Self, Error>
where Self: From<<Self::SolType as SolType>::RustType>,

ABI-decode this type from the given data. Read more
§

fn abi_decode_params<'de>( data: &'de [u8], validate: bool, ) -> Result<Self, Error>
where Self: From<<Self::SolType as SolType>::RustType>, <Self::SolType as SolType>::Token<'de>: TokenSeq<'de>,

ABI-decode this type from the given data. Read more
§

fn abi_decode_sequence<'de>( data: &'de [u8], validate: bool, ) -> Result<Self, Error>
where Self: From<<Self::SolType as SolType>::RustType>, <Self::SolType as SolType>::Token<'de>: TokenSeq<'de>,

ABI-decode this type from the given data. Read more