EntriesManager
EntriesManager
Manager contract that handles the acquisition of Raffl
entries.
*This is an extract of @cygaar_dev and @vectorized.eth ERC721A contract in order to manage efficient minting of entries. Assumptions:
- An owner cannot mint more than 2**64 - 1 (type(uint64).max).
- The maximum entry ID cannot exceed 2**256 - 1 (type(uint256).max).*
State Variables
_BITMASK_ADDRESS_DATA_ENTRY
Mask of an entry in packed address data.
_BITPOS_NUMBER_MINTED
The bit position of numberMinted
in packed address data.
_BITMASK_ADDRESS
The mask of the lower 160 bits for addresses.
_currentIndex
The next entry ID to be minted.
_packedOwnerships
_packedAddressData
Functions
totalEntries
Returns the total amount of entries minted in the contract.
balanceOf
Returns the number of entries in owner
’s account.
ownerOf
*Returns the owner of the entryId
.
Requirements:
entryId
must exist.*
_packedOwnershipOf
Returns the packed ownership data of entryId
.
_packOwnershipData
Packs ownership data into a single uint256.
_mint
*Mints quantity
entries and transfers them to to
.
Requirements:
to
cannot be the zero address.quantity
must be greater than 0.*
_revert
For more efficient reverts.
Errors
BalanceQueryForZeroAddress
Cannot query the balance for the zero address.
OwnerQueryForNonexistentEntry
The entry does not exist.