Created
April 20, 2020 17:04
-
-
Save mariano-aguero/bc70f23ff8eaa453c2c9b888d07676c3 to your computer and use it in GitHub Desktop.
FA 1.2 entry points
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function main (const action : tokenAction ; const store : store) : return is | |
block { | |
if amount =/= 0tz then failwith ("This contract do not accept token amount"); | |
else skip; | |
} with case action of | |
GetAllowance(n) -> allowance(n.0, n.1, n.2, store) | |
| Transfer(n) -> transfer(n.0, n.1, n.2, store) | |
| Approve(n) -> approve(n.0, n.1, store) | |
| GetBalance(n) -> balanceOf(n.0, n.1, store) | |
| GetTotalSupply(n) -> totalSupply(n.1, store) | |
| Mint(n) -> mint(n, store) | |
| Burn(n) -> burn(n, store) | |
| Decimals(n) -> decimals(n.1, store) | |
| Symbol(n) -> symbol(n.1, store) | |
| Name(n) -> name(n.1, store) | |
end; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment