pub enum AbiToken {
Uint(Uint256),
Int(Int256),
Address(Address),
Bool(bool),
String(String),
FixedString(String),
Bytes(Vec<u8>),
UnboundedBytes(Vec<u8>),
Dynamic(Vec<AbiToken>),
Struct(Vec<AbiToken>),
}
Expand description
A token represents a value of parameter of the contract call.
For each supported type there is separate entry that later is helpful to determine actual byte representation.
Variants§
Uint(Uint256)
Unsigned type with value already encoded.
Int(Int256)
Signed type with value already encoded.
Address(Address)
Ethereum Address
Bool(bool)
A boolean logic
String(String)
Represents a string
FixedString(String)
Represents a string encoded into a fixed size bytes32
Bytes(Vec<u8>)
Fixed size array of bytes
UnboundedBytes(Vec<u8>)
This is a dynamic array of bytes that reflects dynamic “bytes” type in Solidity
Dynamic(Vec<AbiToken>)
Dynamic array with supported values of supported types already converted
Struct(Vec<AbiToken>)
A struct to be encoded as a contract call argument
Implementations§
source§impl AbiToken
impl AbiToken
sourcepub fn serialize(&self) -> SerializedToken
pub fn serialize(&self) -> SerializedToken
Serializes a token into a SerializedToken
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AbiToken
impl RefUnwindSafe for AbiToken
impl Send for AbiToken
impl Sync for AbiToken
impl Unpin for AbiToken
impl UnwindSafe for AbiToken
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more