ILoyaltyPoints Contract
This interface defines the functions that the LoyaltyPoints contract implements. This allows for other contracts to interact with the LoyaltyPoints contract in a standardized way.
Functions
mint(address to, uint256 amount): Mints loyalty points to a given address.
burn(address from, uint256 amount): Burns loyalty points from a given address.
balanceOf(address account): Returns the balance of loyalty points for a given address.
transfer(address to, uint256 amount): Transfers loyalty points from the caller's address to a given address.
approve(address spender, uint256 amount): Allows a spender to transfer loyalty points from the caller's address.
transferFrom(address from, address to, uint256 amount): Transfers loyalty points from one address to another, where the caller must have been approved by the "from" address.
allowance(address owner, address spender): Returns the amount of loyalty points that a spender is allowed to transfer from an owner's address.
getTotalSupply(): Returns the total supply of loyalty points.
Events
Transfer(address indexed from, address indexed to, uint256 amount): Emitted when loyalty points are transferred.
Approval(address indexed owner, address indexed spender, uint256 amount): Emitted when an approval is granted.