TokenV2.sol
Type: Standard ERC20 (Ownable)
Description: ERC20 token with (1) configurable transfer fees, (2) fee exemptions, and (3) trading lock mechanism that blocks transfers until the owner permanently enables trading (with trading-exempt bypass addresses). Includes owner-controlled mint and public burn.
State Variables
feeBasisPoints
uint256
public
Transfer fee in basis points (100 =1%)
MAX_FEE_BPS
uint256
public constant
Maximum fee allowed
feeCollector
address
public
Address receiving fees
feeEnabled
bool
public
Enables/disables fee logic
isFeeExempt
mapping(address => bool)
public
Fee exemption list
tradingEnabled
bool
public
Global trading switch
tradingPermanentlyEnabled
bool
public
One-way permanent trading enable flag
isTradingExempt
mapping(address => bool)
public
Trading lock exemption list
totalSupply
uint256
public
Total token supply
Access Control Matrix
enableTrading
❌
✅
Permanently enables trading (one-way)
setTradingExempt
❌
✅
Bypass trading lock
setFee
❌
✅
Max 300 bps
setFeeCollector
❌
✅
Non-zero address
setFeeExempt
❌
✅
Toggle fee exemption
setFeeEnabled
❌
✅
Enable/disable fee
mint
❌
✅
Unlimited mint
burn
✅
❌
Self-burn only
transfer
✅
❌
Trading lock + fee logic may apply
transferFrom
✅
❌
Trading lock + fee logic may apply
Last updated