OptimismMintableERC20

World Chain ERC-20 Token

0x2cfc85d8e48f8eab294be644d9e25c3030863003

Solidity v0.8.15+commit.e14f2714

Fungible token following the ERC-20 standard.

🤖
透過你的 AI 查詢此合約
參考: 0x2cfc85d8e48f8eab294be644d9e25c3030863003
範例提示詞: "Tell me the current state of world/0x2cfc85d8e48f8eab294be644d9e25c3030863003"
還沒有接入 AI?→ mcp.smarts.md
World Chain 在 Smarts 上是僅文件鏈:原始碼和 ABI 已索引,但目前不提供即時鏈上資料(狀態、最新事件、管理員概覽)。AI 代理仍可透過 MCP 呼叫 get_contract_info 和 get_contract_source。

概覽

讀取函式
14
寫入函式
7
事件
4

讀取函式

BRIDGE() view

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
REMOTE_TOKEN() view

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
allowance(owner: address, spender: address) view

Returns the remaining number of tokens that spender is allowed to spend on behalf of owner.✨ AI

開發者: See {IERC20-allowance}.

參數

名稱 類型 描述
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
balanceOf(account: address) view

Returns the token balance of the given account.✨ AI

開發者: See {IERC20-balanceOf}.

參數

名稱 類型 描述
account address Address whose token balance will be returned.✨ AI

回傳值

名稱 類型 描述
uint256 The number of tokens owned by the account as an unsigned integer.✨ AI
bridge() view

Legacy getter for BRIDGE.

回傳值

名稱 類型 描述
address
decimals() view

Return the number of decimal places used by the token.✨ AI

開發者: Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5.05` (`505 / 10 ** 2`). NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}.

回傳值

名稱 類型 描述
uint8 The token's decimal precision as a uint8 value.✨ AI
l1Token() view

Legacy getter for the remote token. Use REMOTE_TOKEN going forward.

回傳值

名稱 類型 描述
address
l2Bridge() view

Legacy getter for the bridge. Use BRIDGE going forward.

回傳值

名稱 類型 描述
address
name() view

Returns the token's name.✨ AI

開發者: Returns the name of the token.

回傳值

名稱 類型 描述
string The token name as a string.✨ AI
remoteToken() view

Legacy getter for REMOTE_TOKEN.

回傳值

名稱 類型 描述
address
supportsInterface(_interfaceId: bytes4) pure

ERC165 interface check function.

參數

名稱 類型 描述
_interfaceId bytes4 Interface ID to check.

回傳值

名稱 類型 描述
bool Whether or not the interface is supported by this contract.
symbol() view

Get the token's short ticker symbol.✨ AI

開發者: Returns the symbol of the token, usually a shorter version of the name.

回傳值

名稱 類型 描述
string The token's symbol as a string (ERC-20 short ticker).✨ AI
totalSupply() view

Returns the total number of tokens in existence.✨ AI

開發者: See {IERC20-totalSupply}.

回傳值

名稱 類型 描述
uint256 Total token supply as a uint256.✨ AI
version() view

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(spender: address, amount: uint256) nonpayable

Approve a spender to transfer up to a specified amount of tokens from your account.✨ AI

開發者: See {IERC20-approve}. NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on `transferFrom`. This is semantically equivalent to an infinite approval. Requirements: - `spender` cannot be the zero address.

參數

名稱 類型 描述
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
burn(_from: address, _amount: uint256) nonpayable

Allows the StandardBridge on this network to burn tokens.

參數

名稱 類型 描述
_from address Address to burn tokens from.
_amount uint256 Amount of tokens to burn.
decreaseAllowance(spender: address, subtractedValue: uint256) nonpayable

Decrease the caller's token allowance for a spender by subtractedValue.✨ AI

開發者: Atomically decreases the allowance granted to `spender` by the caller. This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. Emits an {Approval} event indicating the updated allowance. Requirements: - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.

參數

名稱 類型 描述
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
increaseAllowance(spender: address, addedValue: uint256) nonpayable

Increase the caller's ERC-20 allowance for the spender by addedValue.✨ AI

開發者: Atomically increases the allowance granted to `spender` by the caller. This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. Emits an {Approval} event indicating the updated allowance. Requirements: - `spender` cannot be the zero address.

參數

名稱 類型 描述
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
mint(_to: address, _amount: uint256) nonpayable

Allows the StandardBridge on this network to mint tokens.

參數

名稱 類型 描述
_to address Address to mint tokens to.
_amount uint256 Amount of tokens to mint.
transfer(to: address, amount: uint256) nonpayable

Transfer tokens from the caller to the specified address.✨ AI

開發者: See {IERC20-transfer}. Requirements: - `to` cannot be the zero address. - the caller must have a balance of at least `amount`.

參數

名稱 類型 描述
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
transferFrom(from: address, to: address, amount: uint256) nonpayable

Transfer tokens from one account to another using the caller's allowance.✨ AI

開發者: See {IERC20-transferFrom}. Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}. NOTE: Does not update the allowance if the current allowance is the maximum `uint256`. Requirements: - `from` and `to` cannot be the zero address. - `from` must have a balance of at least `amount`. - the caller must have allowance for ``from``'s tokens of at least `amount`.

參數

名稱 類型 描述
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

事件

Approval(owner: address, spender: address, value: uint256)
名稱 類型 已索引 描述
owner address
spender address
value uint256
Burn(account: address, amount: 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.
Mint(account: address, amount: uint256)

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.
Transfer(from: address, to: address, value: uint256)
名稱 類型 已索引 描述
from address
to address
value uint256