ContractsCollectionToken

CollectionToken

Contracts/src/contracts/CollectionToken.sol

A minimal ERC-20 clone deployed once per collection by Locker.createCollection. Mint and burn rights are restricted to the owning Locker — there is no public mint path.

CollectionToken is also the unit of account for the V4 pool, listings, and shutdown claims.

Each collection has exactly one CollectionToken. Look it up via Locker.collectionToken(_collection) rather than maintaining a parallel registry.

Public surface

CollectionToken exposes the standard IERC20 interface plus four extra methods intended for the Locker / shutdown flows:

FunctionCallerDescription
initialize(name_, symbol_)Locker (one-shot)Sets metadata at clone deployment
mint(_to, _amount)LockerMint on Locker.deposit
setMetadata(name_, symbol_)Locker / ownerUpdate display metadata
burn(value)Anyone (their own balance)Standard burn
burnFrom(account, value)Approved spenderStandard burn-from

The standard ERC-20 surface (balanceOf, transfer, transferFrom, approve, allowance, totalSupply, name, symbol, decimals) is unchanged.

Pricing semantics

  • Decimals: 18.
  • 1 NFT in the floor pool ↔ 1e18 CollectionToken (mint/burn pair on Locker.deposit / Locker.redeem).
  • Listings sell their NFTs at floorMultiple/100 CollectionToken, paying the premium ((floorMultiple - 100) / 100) to the listing owner and burning the floor portion (1) from the buyer.

Inherited surface

  • IERC20 (OpenZeppelin) — the full standard interface.
  • Ownable — owner is the Locker; mint/setMetadata gated.
  • EIP-2612 permit support is not included on the bare CollectionToken; use Permit2 if you need approval-less flows (the NFTXZap path covers this).