Expand description
Generated by the following Solidity interface…
interface MockERC20 {
error AllowanceOverflow();
error AllowanceUnderflow();
error InsufficientAllowance();
error InsufficientBalance();
error InvalidPermit();
error Permit2AllowanceIsFixedAtInfinity();
error PermitExpired();
error TotalSupplyOverflow();
event Approval(address indexed owner, address indexed spender, uint256 amount);
event Transfer(address indexed from, address indexed to, uint256 amount);
constructor(string name_, string symbol_, uint8 decimals_);
function DOMAIN_SEPARATOR() external view returns (bytes32 result);
function allowance(address owner, address spender) external view returns (uint256 result);
function approve(address spender, uint256 amount) external returns (bool);
function balanceOf(address owner) external view returns (uint256 result);
function burn(address from, uint256 value) external;
function decimals() external view returns (uint8);
function directSpendAllowance(address owner, address spender, uint256 amount) external;
function directTransfer(address from, address to, uint256 amount) external;
function mint(address to, uint256 value) external;
function name() external view returns (string memory);
function nonces(address owner) external view returns (uint256 result);
function permit(address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) external;
function symbol() external view returns (string memory);
function totalSupply() external view returns (uint256 result);
function transfer(address to, uint256 amount) external returns (bool);
function transferFrom(address from, address to, uint256 amount) external returns (bool);
}…which was generated by the following JSON ABI:
[
{
"type": "constructor",
"inputs": [
{
"name": "name_",
"type": "string",
"internalType": "string"
},
{
"name": "symbol_",
"type": "string",
"internalType": "string"
},
{
"name": "decimals_",
"type": "uint8",
"internalType": "uint8"
}
],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "DOMAIN_SEPARATOR",
"inputs": [],
"outputs": [
{
"name": "result",
"type": "bytes32",
"internalType": "bytes32"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "allowance",
"inputs": [
{
"name": "owner",
"type": "address",
"internalType": "address"
},
{
"name": "spender",
"type": "address",
"internalType": "address"
}
],
"outputs": [
{
"name": "result",
"type": "uint256",
"internalType": "uint256"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "approve",
"inputs": [
{
"name": "spender",
"type": "address",
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [
{
"name": "",
"type": "bool",
"internalType": "bool"
}
],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "balanceOf",
"inputs": [
{
"name": "owner",
"type": "address",
"internalType": "address"
}
],
"outputs": [
{
"name": "result",
"type": "uint256",
"internalType": "uint256"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "burn",
"inputs": [
{
"name": "from",
"type": "address",
"internalType": "address"
},
{
"name": "value",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "decimals",
"inputs": [],
"outputs": [
{
"name": "",
"type": "uint8",
"internalType": "uint8"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "directSpendAllowance",
"inputs": [
{
"name": "owner",
"type": "address",
"internalType": "address"
},
{
"name": "spender",
"type": "address",
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "directTransfer",
"inputs": [
{
"name": "from",
"type": "address",
"internalType": "address"
},
{
"name": "to",
"type": "address",
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "mint",
"inputs": [
{
"name": "to",
"type": "address",
"internalType": "address"
},
{
"name": "value",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "name",
"inputs": [],
"outputs": [
{
"name": "",
"type": "string",
"internalType": "string"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "nonces",
"inputs": [
{
"name": "owner",
"type": "address",
"internalType": "address"
}
],
"outputs": [
{
"name": "result",
"type": "uint256",
"internalType": "uint256"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "permit",
"inputs": [
{
"name": "owner",
"type": "address",
"internalType": "address"
},
{
"name": "spender",
"type": "address",
"internalType": "address"
},
{
"name": "value",
"type": "uint256",
"internalType": "uint256"
},
{
"name": "deadline",
"type": "uint256",
"internalType": "uint256"
},
{
"name": "v",
"type": "uint8",
"internalType": "uint8"
},
{
"name": "r",
"type": "bytes32",
"internalType": "bytes32"
},
{
"name": "s",
"type": "bytes32",
"internalType": "bytes32"
}
],
"outputs": [],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "symbol",
"inputs": [],
"outputs": [
{
"name": "",
"type": "string",
"internalType": "string"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "totalSupply",
"inputs": [],
"outputs": [
{
"name": "result",
"type": "uint256",
"internalType": "uint256"
}
],
"stateMutability": "view"
},
{
"type": "function",
"name": "transfer",
"inputs": [
{
"name": "to",
"type": "address",
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [
{
"name": "",
"type": "bool",
"internalType": "bool"
}
],
"stateMutability": "nonpayable"
},
{
"type": "function",
"name": "transferFrom",
"inputs": [
{
"name": "from",
"type": "address",
"internalType": "address"
},
{
"name": "to",
"type": "address",
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"internalType": "uint256"
}
],
"outputs": [
{
"name": "",
"type": "bool",
"internalType": "bool"
}
],
"stateMutability": "nonpayable"
},
{
"type": "event",
"name": "Approval",
"inputs": [
{
"name": "owner",
"type": "address",
"indexed": true,
"internalType": "address"
},
{
"name": "spender",
"type": "address",
"indexed": true,
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"indexed": false,
"internalType": "uint256"
}
],
"anonymous": false
},
{
"type": "event",
"name": "Transfer",
"inputs": [
{
"name": "from",
"type": "address",
"indexed": true,
"internalType": "address"
},
{
"name": "to",
"type": "address",
"indexed": true,
"internalType": "address"
},
{
"name": "amount",
"type": "uint256",
"indexed": false,
"internalType": "uint256"
}
],
"anonymous": false
},
{
"type": "error",
"name": "AllowanceOverflow",
"inputs": []
},
{
"type": "error",
"name": "AllowanceUnderflow",
"inputs": []
},
{
"type": "error",
"name": "InsufficientAllowance",
"inputs": []
},
{
"type": "error",
"name": "InsufficientBalance",
"inputs": []
},
{
"type": "error",
"name": "InvalidPermit",
"inputs": []
},
{
"type": "error",
"name": "Permit2AllowanceIsFixedAtInfinity",
"inputs": []
},
{
"type": "error",
"name": "PermitExpired",
"inputs": []
},
{
"type": "error",
"name": "TotalSupplyOverflow",
"inputs": []
}
]Structs§
- Allowance
Overflow - Custom error with signature
AllowanceOverflow()and selector0xf9067066. - Allowance
Underflow - Custom error with signature
AllowanceUnderflow()and selector0x8301ab38. - Approval
- Event with signature
Approval(address,address,uint256)and selector0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925. - DOMAIN_
SEPARATOR Call - Function with signature
DOMAIN_SEPARATOR()and selector0x3644e515. - DOMAIN_
SEPARATOR Return - Container type for the return parameters of the
DOMAIN_SEPARATOR()function. - Insufficient
Allowance - Custom error with signature
InsufficientAllowance()and selector0x13be252b. - Insufficient
Balance - Custom error with signature
InsufficientBalance()and selector0xf4d678b8. - Invalid
Permit - Custom error with signature
InvalidPermit()and selector0xddafbaef. - MockER
C20Instance - A
MockERC20instance. - Permit2
Allowance IsFixed AtInfinity - Custom error with signature
Permit2AllowanceIsFixedAtInfinity()and selector0x3f68539a. - Permit
Expired - Custom error with signature
PermitExpired()and selector0x1a15a3cc. - Total
Supply Overflow - Custom error with signature
TotalSupplyOverflow()and selector0xe5cfe957. - Transfer
- Event with signature
Transfer(address,address,uint256)and selector0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef. - allowance
Call - Function with signature
allowance(address,address)and selector0xdd62ed3e. - allowance
Return - Container type for the return parameters of the
allowance(address,address)function. - approve
Call - Function with signature
approve(address,uint256)and selector0x095ea7b3. - approve
Return - Container type for the return parameters of the
approve(address,uint256)function. - balance
OfCall - Function with signature
balanceOf(address)and selector0x70a08231. - balance
OfReturn - Container type for the return parameters of the
balanceOf(address)function. - burn
Call - Function with signature
burn(address,uint256)and selector0x9dc29fac. - burn
Return - Container type for the return parameters of the
burn(address,uint256)function. - constructor
Call - Constructor`.
- decimals
Call - Function with signature
decimals()and selector0x313ce567. - decimals
Return - Container type for the return parameters of the
decimals()function. - direct
Spend Allowance Call - Function with signature
directSpendAllowance(address,address,uint256)and selector0xd30ed3b3. - direct
Spend Allowance Return - Container type for the return parameters of the
directSpendAllowance(address,address,uint256)function. - direct
Transfer Call - Function with signature
directTransfer(address,address,uint256)and selector0xf83d1791. - direct
Transfer Return - Container type for the return parameters of the
directTransfer(address,address,uint256)function. - mint
Call - Function with signature
mint(address,uint256)and selector0x40c10f19. - mint
Return - Container type for the return parameters of the
mint(address,uint256)function. - name
Call - Function with signature
name()and selector0x06fdde03. - name
Return - Container type for the return parameters of the
name()function. - nonces
Call - Function with signature
nonces(address)and selector0x7ecebe00. - nonces
Return - Container type for the return parameters of the
nonces(address)function. - permit
Call - Function with signature
permit(address,address,uint256,uint256,uint8,bytes32,bytes32)and selector0xd505accf. - permit
Return - Container type for the return parameters of the
permit(address,address,uint256,uint256,uint8,bytes32,bytes32)function. - symbol
Call - Function with signature
symbol()and selector0x95d89b41. - symbol
Return - Container type for the return parameters of the
symbol()function. - total
Supply Call - Function with signature
totalSupply()and selector0x18160ddd. - total
Supply Return - Container type for the return parameters of the
totalSupply()function. - transfer
Call - Function with signature
transfer(address,uint256)and selector0xa9059cbb. - transfer
From Call - Function with signature
transferFrom(address,address,uint256)and selector0x23b872dd. - transfer
From Return - Container type for the return parameters of the
transferFrom(address,address,uint256)function. - transfer
Return - Container type for the return parameters of the
transfer(address,uint256)function.
Enums§
- MockER
C20Calls - Container for all the
MockERC20function calls. - MockER
C20Errors - Container for all the
MockERC20custom errors. - MockER
C20Events - Container for all the
MockERC20events.
Statics§
- BYTECODE
- The creation / init bytecode of the contract.
- DEPLOYED_
BYTECODE - The runtime bytecode of the contract, as deployed on the network.
Functions§
- deploy
- Deploys this contract using the given
providerand constructor arguments, if any. - deploy_
builder - Creates a
RawCallBuilderfor deploying this contract using the givenproviderand constructor arguments, if any. - new
- Creates a new wrapper around an on-chain
MockERC20contract instance.