Smart Contract
IEVMBridgeTokenMinter
A.1e4aa0b87d10b141.IEVMBridgeTokenMinter
1import FungibleToken from 0xf233dcee88fe0abe
2
3/// Contract interface enabling FlowEVMBridge to mint fungible tokens from implementing bridge contracts.
4///
5access(all)
6contract interface IEVMBridgeTokenMinter {
7
8 /// Emitted whenever tokens are minted, identifying the type, amount, and minter
9 access(all) event Minted(type: String, amount: UFix64, mintedUUID: UInt64, minter: Address)
10
11 /// Account-only method to mint a fungible token of the specified amount.
12 ///
13 access(account)
14 fun mintTokens(amount: UFix64): @{FungibleToken.Vault} {
15 post {
16 result.balance == amount: "Result does not contained specified amount"
17 emit Minted(
18 type: result.getType().identifier,
19 amount: amount,
20 mintedUUID: result.uuid,
21 minter: self.account.address
22 )
23 }
24 }
25}
26