pub use erc20_capped::*;
/// This module was auto-generated with ethers-rs Abigen.
/// More information at: <https://github.com/gakonst/ethers-rs>
#[allow(
clippy::enum_variant_names,
clippy::too_many_arguments,
clippy::upper_case_acronyms,
clippy::type_complexity,
dead_code,
non_camel_case_types,
)]
pub mod erc20_capped {
#[rustfmt::skip]
const __ABI: &str = "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\",\"components\":[],\"indexed\":true},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\",\"components\":[],\"indexed\":true},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"Approval\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\",\"components\":[],\"indexed\":true},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\",\"components\":[],\"indexed\":true},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\",\"components\":[],\"indexed\":false}],\"type\":\"event\",\"name\":\"Transfer\",\"outputs\":[],\"anonymous\":false},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\",\"components\":[]}],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"cap\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\",\"components\":[]}]},{\"inputs\":[],\"stateMutability\":\"view\",\"type\":\"function\",\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\",\"components\":[]},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\",\"components\":[]}],\"stateMutability\":\"nonpayable\",\"type\":\"function\",\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\",\"components\":[]}]}]";
///The parsed JSON ABI of the contract.
pub static ERC20CAPPED_ABI: ::ethers_contract::Lazy<::ethers_core::abi::Abi> = ::ethers_contract::Lazy::new(||
::ethers_core::utils::__serde_json::from_str(__ABI).expect("ABI is always valid"));
pub struct ERC20Capped<M>(::ethers_contract::Contract<M>);
impl<M> ::core::clone::Clone for ERC20Capped<M> {
fn clone(&self) -> Self {
Self(::core::clone::Clone::clone(&self.0))
}
}
impl<M> ::core::ops::Deref for ERC20Capped<M> {
type Target = ::ethers_contract::Contract<M>;
fn deref(&self) -> &Self::Target {
&self.0
}
}
impl<M> ::core::ops::DerefMut for ERC20Capped<M> {
fn deref_mut(&mut self) -> &mut Self::Target {
&mut self.0
}
}
impl<M> ::core::fmt::Debug for ERC20Capped<M> {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
f.debug_tuple(stringify!(ERC20Capped)).field(&self.address()).finish()
}
}
impl<M: ::ethers_providers::Middleware> ERC20Capped<M> {
/// Creates a new contract instance with the specified `ethers` client at
/// `address`. The contract derefs to a `ethers::Contract` object.
pub fn new<T: Into<::ethers_core::types::Address>>(
address: T,
client: ::std::sync::Arc<M>,
) -> Self {
Self(
::ethers_contract::Contract::new(
address.into(),
ERC20CAPPED_ABI.clone(),
client,
),
)
}
///Calls the contract's `allowance` (0xdd62ed3e) function
pub fn allowance(
&self,
owner: ::ethers_core::types::Address,
spender: ::ethers_core::types::Address,
) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
self.0
.method_hash([221, 98, 237, 62], (owner, spender))
.expect("method not found (this should never happen)")
}
///Calls the contract's `approve` (0x095ea7b3) function
pub fn approve(
&self,
spender: ::ethers_core::types::Address,
amount: ::ethers_core::types::U256,
) -> ::ethers_contract::builders::ContractCall<M, bool> {
self.0
.method_hash([9, 94, 167, 179], (spender, amount))
.expect("method not found (this should never happen)")
}
///Calls the contract's `balanceOf` (0x70a08231) function
pub fn balance_of(
&self,
account: ::ethers_core::types::Address,
) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
self.0
.method_hash([112, 160, 130, 49], account)
.expect("method not found (this should never happen)")
}
///Calls the contract's `cap` (0x355274ea) function
pub fn cap(
&self,
) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
self.0
.method_hash([53, 82, 116, 234], ())
.expect("method not found (this should never happen)")
}
///Calls the contract's `decimals` (0x313ce567) function
pub fn decimals(&self) -> ::ethers_contract::builders::ContractCall<M, u8> {
self.0
.method_hash([49, 60, 229, 103], ())
.expect("method not found (this should never happen)")
}
///Calls the contract's `decreaseAllowance` (0xa457c2d7) function
pub fn decrease_allowance(
&self,
spender: ::ethers_core::types::Address,
subtracted_value: ::ethers_core::types::U256,
) -> ::ethers_contract::builders::ContractCall<M, bool> {
self.0
.method_hash([164, 87, 194, 215], (spender, subtracted_value))
.expect("method not found (this should never happen)")
}
///Calls the contract's `increaseAllowance` (0x39509351) function
pub fn increase_allowance(
&self,
spender: ::ethers_core::types::Address,
added_value: ::ethers_core::types::U256,
) -> ::ethers_contract::builders::ContractCall<M, bool> {
self.0
.method_hash([57, 80, 147, 81], (spender, added_value))
.expect("method not found (this should never happen)")
}
///Calls the contract's `name` (0x06fdde03) function
pub fn name(
&self,
) -> ::ethers_contract::builders::ContractCall<M, ::std::string::String> {
self.0
.method_hash([6, 253, 222, 3], ())
.expect("method not found (this should never happen)")
}
///Calls the contract's `symbol` (0x95d89b41) function
pub fn symbol(
&self,
) -> ::ethers_contract::builders::ContractCall<M, ::std::string::String> {
self.0
.method_hash([149, 216, 155, 65], ())
.expect("method not found (this should never happen)")
}
///Calls the contract's `totalSupply` (0x18160ddd) function
pub fn total_supply(
&self,
) -> ::ethers_contract::builders::ContractCall<M, ::ethers_core::types::U256> {
self.0
.method_hash([24, 22, 13, 221], ())
.expect("method not found (this should never happen)")
}
///Calls the contract's `transfer` (0xa9059cbb) function
pub fn transfer(
&self,
to: ::ethers_core::types::Address,
amount: ::ethers_core::types::U256,
) -> ::ethers_contract::builders::ContractCall<M, bool> {
self.0
.method_hash([169, 5, 156, 187], (to, amount))
.expect("method not found (this should never happen)")
}
///Calls the contract's `transferFrom` (0x23b872dd) function
pub fn transfer_from(
&self,
from: ::ethers_core::types::Address,
to: ::ethers_core::types::Address,
amount: ::ethers_core::types::U256,
) -> ::ethers_contract::builders::ContractCall<M, bool> {
self.0
.method_hash([35, 184, 114, 221], (from, to, amount))
.expect("method not found (this should never happen)")
}
///Gets the contract's `Approval` event
pub fn approval_filter(
&self,
) -> ::ethers_contract::builders::Event<::std::sync::Arc<M>, M, ApprovalFilter> {
self.0.event()
}
///Gets the contract's `Transfer` event
pub fn transfer_filter(
&self,
) -> ::ethers_contract::builders::Event<::std::sync::Arc<M>, M, TransferFilter> {
self.0.event()
}
/// Returns an `Event` builder for all the events of this contract.
pub fn events(
&self,
) -> ::ethers_contract::builders::Event<
::std::sync::Arc<M>,
M,
ERC20CappedEvents,
> {
self.0.event_with_filter(::core::default::Default::default())
}
}
impl<M: ::ethers_providers::Middleware> From<::ethers_contract::Contract<M>>
for ERC20Capped<M> {
fn from(contract: ::ethers_contract::Contract<M>) -> Self {
Self::new(contract.address(), contract.client())
}
}
#[derive(
Clone,
::ethers_contract::EthEvent,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethevent(name = "Approval", abi = "Approval(address,address,uint256)")]
pub struct ApprovalFilter {
#[ethevent(indexed)]
pub owner: ::ethers_core::types::Address,
#[ethevent(indexed)]
pub spender: ::ethers_core::types::Address,
pub value: ::ethers_core::types::U256,
}
#[derive(
Clone,
::ethers_contract::EthEvent,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethevent(name = "Transfer", abi = "Transfer(address,address,uint256)")]
pub struct TransferFilter {
#[ethevent(indexed)]
pub from: ::ethers_core::types::Address,
#[ethevent(indexed)]
pub to: ::ethers_core::types::Address,
pub value: ::ethers_core::types::U256,
}
///Container type for all of the contract's events
#[derive(Clone, ::ethers_contract::EthAbiType, Debug, PartialEq, Eq, Hash)]
pub enum ERC20CappedEvents {
ApprovalFilter(ApprovalFilter),
TransferFilter(TransferFilter),
}
impl ::ethers_contract::EthLogDecode for ERC20CappedEvents {
fn decode_log(
log: &::ethers_core::abi::RawLog,
) -> ::core::result::Result<Self, ::ethers_core::abi::Error> {
if let Ok(decoded) = ApprovalFilter::decode_log(log) {
return Ok(ERC20CappedEvents::ApprovalFilter(decoded));
}
if let Ok(decoded) = TransferFilter::decode_log(log) {
return Ok(ERC20CappedEvents::TransferFilter(decoded));
}
Err(::ethers_core::abi::Error::InvalidData)
}
}
impl ::core::fmt::Display for ERC20CappedEvents {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
match self {
Self::ApprovalFilter(element) => ::core::fmt::Display::fmt(element, f),
Self::TransferFilter(element) => ::core::fmt::Display::fmt(element, f),
}
}
}
impl ::core::convert::From<ApprovalFilter> for ERC20CappedEvents {
fn from(value: ApprovalFilter) -> Self {
Self::ApprovalFilter(value)
}
}
impl ::core::convert::From<TransferFilter> for ERC20CappedEvents {
fn from(value: TransferFilter) -> Self {
Self::TransferFilter(value)
}
}
///Container type for all input parameters for the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "allowance", abi = "allowance(address,address)")]
pub struct AllowanceCall {
pub owner: ::ethers_core::types::Address,
pub spender: ::ethers_core::types::Address,
}
///Container type for all input parameters for the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "approve", abi = "approve(address,uint256)")]
pub struct ApproveCall {
pub spender: ::ethers_core::types::Address,
pub amount: ::ethers_core::types::U256,
}
///Container type for all input parameters for the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "balanceOf", abi = "balanceOf(address)")]
pub struct BalanceOfCall {
pub account: ::ethers_core::types::Address,
}
///Container type for all input parameters for the `cap` function with signature `cap()` and selector `0x355274ea`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "cap", abi = "cap()")]
pub struct CapCall;
///Container type for all input parameters for the `decimals` function with signature `decimals()` and selector `0x313ce567`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "decimals", abi = "decimals()")]
pub struct DecimalsCall;
///Container type for all input parameters for the `decreaseAllowance` function with signature `decreaseAllowance(address,uint256)` and selector `0xa457c2d7`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "decreaseAllowance", abi = "decreaseAllowance(address,uint256)")]
pub struct DecreaseAllowanceCall {
pub spender: ::ethers_core::types::Address,
pub subtracted_value: ::ethers_core::types::U256,
}
///Container type for all input parameters for the `increaseAllowance` function with signature `increaseAllowance(address,uint256)` and selector `0x39509351`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "increaseAllowance", abi = "increaseAllowance(address,uint256)")]
pub struct IncreaseAllowanceCall {
pub spender: ::ethers_core::types::Address,
pub added_value: ::ethers_core::types::U256,
}
///Container type for all input parameters for the `name` function with signature `name()` and selector `0x06fdde03`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "name", abi = "name()")]
pub struct NameCall;
///Container type for all input parameters for the `symbol` function with signature `symbol()` and selector `0x95d89b41`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "symbol", abi = "symbol()")]
pub struct SymbolCall;
///Container type for all input parameters for the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "totalSupply", abi = "totalSupply()")]
pub struct TotalSupplyCall;
///Container type for all input parameters for the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "transfer", abi = "transfer(address,uint256)")]
pub struct TransferCall {
pub to: ::ethers_core::types::Address,
pub amount: ::ethers_core::types::U256,
}
///Container type for all input parameters for the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd`
#[derive(
Clone,
::ethers_contract::EthCall,
::ethers_contract::EthDisplay,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
#[ethcall(name = "transferFrom", abi = "transferFrom(address,address,uint256)")]
pub struct TransferFromCall {
pub from: ::ethers_core::types::Address,
pub to: ::ethers_core::types::Address,
pub amount: ::ethers_core::types::U256,
}
///Container type for all of the contract's call
#[derive(Clone, ::ethers_contract::EthAbiType, Debug, PartialEq, Eq, Hash)]
pub enum ERC20CappedCalls {
Allowance(AllowanceCall),
Approve(ApproveCall),
BalanceOf(BalanceOfCall),
Cap(CapCall),
Decimals(DecimalsCall),
DecreaseAllowance(DecreaseAllowanceCall),
IncreaseAllowance(IncreaseAllowanceCall),
Name(NameCall),
Symbol(SymbolCall),
TotalSupply(TotalSupplyCall),
Transfer(TransferCall),
TransferFrom(TransferFromCall),
}
impl ::ethers_core::abi::AbiDecode for ERC20CappedCalls {
fn decode(
data: impl AsRef<[u8]>,
) -> ::core::result::Result<Self, ::ethers_core::abi::AbiError> {
let data = data.as_ref();
if let Ok(decoded)
= <AllowanceCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Allowance(decoded));
}
if let Ok(decoded)
= <ApproveCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Approve(decoded));
}
if let Ok(decoded)
= <BalanceOfCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::BalanceOf(decoded));
}
if let Ok(decoded)
= <CapCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Cap(decoded));
}
if let Ok(decoded)
= <DecimalsCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Decimals(decoded));
}
if let Ok(decoded)
= <DecreaseAllowanceCall as ::ethers_core::abi::AbiDecode>::decode(
data,
) {
return Ok(Self::DecreaseAllowance(decoded));
}
if let Ok(decoded)
= <IncreaseAllowanceCall as ::ethers_core::abi::AbiDecode>::decode(
data,
) {
return Ok(Self::IncreaseAllowance(decoded));
}
if let Ok(decoded)
= <NameCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Name(decoded));
}
if let Ok(decoded)
= <SymbolCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Symbol(decoded));
}
if let Ok(decoded)
= <TotalSupplyCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::TotalSupply(decoded));
}
if let Ok(decoded)
= <TransferCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::Transfer(decoded));
}
if let Ok(decoded)
= <TransferFromCall as ::ethers_core::abi::AbiDecode>::decode(data) {
return Ok(Self::TransferFrom(decoded));
}
Err(::ethers_core::abi::Error::InvalidData.into())
}
}
impl ::ethers_core::abi::AbiEncode for ERC20CappedCalls {
fn encode(self) -> Vec<u8> {
match self {
Self::Allowance(element) => {
::ethers_core::abi::AbiEncode::encode(element)
}
Self::Approve(element) => ::ethers_core::abi::AbiEncode::encode(element),
Self::BalanceOf(element) => {
::ethers_core::abi::AbiEncode::encode(element)
}
Self::Cap(element) => ::ethers_core::abi::AbiEncode::encode(element),
Self::Decimals(element) => ::ethers_core::abi::AbiEncode::encode(element),
Self::DecreaseAllowance(element) => {
::ethers_core::abi::AbiEncode::encode(element)
}
Self::IncreaseAllowance(element) => {
::ethers_core::abi::AbiEncode::encode(element)
}
Self::Name(element) => ::ethers_core::abi::AbiEncode::encode(element),
Self::Symbol(element) => ::ethers_core::abi::AbiEncode::encode(element),
Self::TotalSupply(element) => {
::ethers_core::abi::AbiEncode::encode(element)
}
Self::Transfer(element) => ::ethers_core::abi::AbiEncode::encode(element),
Self::TransferFrom(element) => {
::ethers_core::abi::AbiEncode::encode(element)
}
}
}
}
impl ::core::fmt::Display for ERC20CappedCalls {
fn fmt(&self, f: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result {
match self {
Self::Allowance(element) => ::core::fmt::Display::fmt(element, f),
Self::Approve(element) => ::core::fmt::Display::fmt(element, f),
Self::BalanceOf(element) => ::core::fmt::Display::fmt(element, f),
Self::Cap(element) => ::core::fmt::Display::fmt(element, f),
Self::Decimals(element) => ::core::fmt::Display::fmt(element, f),
Self::DecreaseAllowance(element) => ::core::fmt::Display::fmt(element, f),
Self::IncreaseAllowance(element) => ::core::fmt::Display::fmt(element, f),
Self::Name(element) => ::core::fmt::Display::fmt(element, f),
Self::Symbol(element) => ::core::fmt::Display::fmt(element, f),
Self::TotalSupply(element) => ::core::fmt::Display::fmt(element, f),
Self::Transfer(element) => ::core::fmt::Display::fmt(element, f),
Self::TransferFrom(element) => ::core::fmt::Display::fmt(element, f),
}
}
}
impl ::core::convert::From<AllowanceCall> for ERC20CappedCalls {
fn from(value: AllowanceCall) -> Self {
Self::Allowance(value)
}
}
impl ::core::convert::From<ApproveCall> for ERC20CappedCalls {
fn from(value: ApproveCall) -> Self {
Self::Approve(value)
}
}
impl ::core::convert::From<BalanceOfCall> for ERC20CappedCalls {
fn from(value: BalanceOfCall) -> Self {
Self::BalanceOf(value)
}
}
impl ::core::convert::From<CapCall> for ERC20CappedCalls {
fn from(value: CapCall) -> Self {
Self::Cap(value)
}
}
impl ::core::convert::From<DecimalsCall> for ERC20CappedCalls {
fn from(value: DecimalsCall) -> Self {
Self::Decimals(value)
}
}
impl ::core::convert::From<DecreaseAllowanceCall> for ERC20CappedCalls {
fn from(value: DecreaseAllowanceCall) -> Self {
Self::DecreaseAllowance(value)
}
}
impl ::core::convert::From<IncreaseAllowanceCall> for ERC20CappedCalls {
fn from(value: IncreaseAllowanceCall) -> Self {
Self::IncreaseAllowance(value)
}
}
impl ::core::convert::From<NameCall> for ERC20CappedCalls {
fn from(value: NameCall) -> Self {
Self::Name(value)
}
}
impl ::core::convert::From<SymbolCall> for ERC20CappedCalls {
fn from(value: SymbolCall) -> Self {
Self::Symbol(value)
}
}
impl ::core::convert::From<TotalSupplyCall> for ERC20CappedCalls {
fn from(value: TotalSupplyCall) -> Self {
Self::TotalSupply(value)
}
}
impl ::core::convert::From<TransferCall> for ERC20CappedCalls {
fn from(value: TransferCall) -> Self {
Self::Transfer(value)
}
}
impl ::core::convert::From<TransferFromCall> for ERC20CappedCalls {
fn from(value: TransferFromCall) -> Self {
Self::TransferFrom(value)
}
}
///Container type for all return fields from the `allowance` function with signature `allowance(address,address)` and selector `0xdd62ed3e`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct AllowanceReturn(pub ::ethers_core::types::U256);
///Container type for all return fields from the `approve` function with signature `approve(address,uint256)` and selector `0x095ea7b3`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct ApproveReturn(pub bool);
///Container type for all return fields from the `balanceOf` function with signature `balanceOf(address)` and selector `0x70a08231`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct BalanceOfReturn(pub ::ethers_core::types::U256);
///Container type for all return fields from the `cap` function with signature `cap()` and selector `0x355274ea`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct CapReturn(pub ::ethers_core::types::U256);
///Container type for all return fields from the `decimals` function with signature `decimals()` and selector `0x313ce567`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct DecimalsReturn(pub u8);
///Container type for all return fields from the `decreaseAllowance` function with signature `decreaseAllowance(address,uint256)` and selector `0xa457c2d7`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct DecreaseAllowanceReturn(pub bool);
///Container type for all return fields from the `increaseAllowance` function with signature `increaseAllowance(address,uint256)` and selector `0x39509351`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct IncreaseAllowanceReturn(pub bool);
///Container type for all return fields from the `name` function with signature `name()` and selector `0x06fdde03`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct NameReturn(pub ::std::string::String);
///Container type for all return fields from the `symbol` function with signature `symbol()` and selector `0x95d89b41`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct SymbolReturn(pub ::std::string::String);
///Container type for all return fields from the `totalSupply` function with signature `totalSupply()` and selector `0x18160ddd`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct TotalSupplyReturn(pub ::ethers_core::types::U256);
///Container type for all return fields from the `transfer` function with signature `transfer(address,uint256)` and selector `0xa9059cbb`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct TransferReturn(pub bool);
///Container type for all return fields from the `transferFrom` function with signature `transferFrom(address,address,uint256)` and selector `0x23b872dd`
#[derive(
Clone,
::ethers_contract::EthAbiType,
::ethers_contract::EthAbiCodec,
Default,
Debug,
PartialEq,
Eq,
Hash
)]
pub struct TransferFromReturn(pub bool);
}