OptimismMintableERC20
World Chain ERC-20 Token0x2cfc85d8e48f8eab294be644d9e25c3030863003
Solidity v0.8.15+commit.e14f2714
Fungible token following the ERC-20 standard.
概覽
讀取函式
Returns the address of the bridge contract that handles cross-chain minting and burning.✨ AI
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | address | Address of the bridge contract used for cross-chain minting and burning.✨ AI |
Return the address of the remote token contract that this mintable ERC-20 represents.✨ AI
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | address | The address of the remote token contract on the other chain that this token maps to.✨ AI |
Returns the remaining number of tokens that spender is allowed to spend on behalf of owner.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| owner | address | Address which owns the tokens.✨ AI |
| spender | address | Address permitted to spend the owner's tokens.✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | uint256 | Remaining allowance in token units that spender may transfer from owner.✨ AI |
Returns the token balance of the given account.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| account | address | Address whose token balance will be returned.✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | uint256 | The number of tokens owned by the account as an unsigned integer.✨ AI |
Legacy getter for BRIDGE.
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | address |
Return the number of decimal places used by the token.✨ AI
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | uint8 | The token's decimal precision as a uint8 value.✨ AI |
Legacy getter for the remote token. Use REMOTE_TOKEN going forward.
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | address |
Legacy getter for the bridge. Use BRIDGE going forward.
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | address |
Returns the token's name.✨ AI
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | string | The token name as a string.✨ AI |
Legacy getter for REMOTE_TOKEN.
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | address |
ERC165 interface check function.
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| _interfaceId | bytes4 | Interface ID to check. |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | bool | Whether or not the interface is supported by this contract. |
Get the token's short ticker symbol.✨ AI
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | string | The token's symbol as a string (ERC-20 short ticker).✨ AI |
Returns the total number of tokens in existence.✨ AI
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | uint256 | Total token supply as a uint256.✨ AI |
Getter for the semantic version of the contract. This is not meant to be used onchain but instead meant to be used by offchain tooling.
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | string | Semver contract version as a string. |
寫入函式
Approve a spender to transfer up to a specified amount of tokens from your account.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| spender | address | Address that will be approved to spend tokens.✨ AI |
| amount | uint256 | Amount of tokens the spender is allowed to transfer (in token smallest units).✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | bool | True if the allowance was successfully set.✨ AI |
Allows the StandardBridge on this network to burn tokens.
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| _from | address | Address to burn tokens from. |
| _amount | uint256 | Amount of tokens to burn. |
Decrease the caller's token allowance for a spender by subtractedValue.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| spender | address | The account whose allowance will be decreased.✨ AI |
| subtractedValue | uint256 | The amount to subtract from the spender's allowance.✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | bool | True if the allowance was decreased successfully.✨ AI |
Increase the caller's ERC-20 allowance for the spender by addedValue.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| spender | address | Address that will be allowed to spend the caller's tokens.✨ AI |
| addedValue | uint256 | Amount of tokens to add to the existing allowance.✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | bool | True if the allowance was increased successfully.✨ AI |
Allows the StandardBridge on this network to mint tokens.
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| _to | address | Address to mint tokens to. |
| _amount | uint256 | Amount of tokens to mint. |
Transfer tokens from the caller to the specified address.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| to | address | Recipient address to receive the tokens.✨ AI |
| amount | uint256 | Amount of tokens to transfer, expressed in the token's smallest unit.✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | bool | True if the transfer succeeded.✨ AI |
Transfer tokens from one account to another using the caller's allowance.✨ AI
參數
| 名稱 | 類型 | 描述 |
|---|---|---|
| from | address | Address to transfer tokens from.✨ AI |
| to | address | Recipient address receiving the tokens.✨ AI |
| amount | uint256 | Amount of tokens to transfer (in token smallest units).✨ AI |
回傳值
| 名稱 | 類型 | 描述 |
|---|---|---|
| — | bool | True if the transfer succeeded.✨ AI |
事件
| 名稱 | 類型 | 已索引 | 描述 |
|---|---|---|---|
| owner | address | ✓ | |
| spender | address | ✓ | |
| value | uint256 |
Emitted whenever tokens are burned from an account.
| 名稱 | 類型 | 已索引 | 描述 |
|---|---|---|---|
| account | address | ✓ | Address of the account tokens are being burned from. |
| amount | uint256 | Amount of tokens burned. |
Emitted whenever tokens are minted for an account.
| 名稱 | 類型 | 已索引 | 描述 |
|---|---|---|---|
| account | address | ✓ | Address of the account tokens are being minted for. |
| amount | uint256 | Amount of tokens minted. |
| 名稱 | 類型 | 已索引 | 描述 |
|---|---|---|---|
| from | address | ✓ | |
| to | address | ✓ | |
| value | uint256 |