Skip to main content

Resource Interface Balance


_10
resource interface Balance {
_10
_10
balance: UFix64
_10
}

The interface that contains the balance field of the Vault and enforces that when new Vaults are created, the balance is initialized correctly.

Functions

fun getViews()


_10
func getViews(): [Type]

Function that returns all the Metadata Views implemented by a Fungible Token

developers to know which parameter to pass to the resolveView() method.

Returns: An array of Types defining the implemented views. This value will be used by


fun resolveView()


_10
func resolveView(_ Type): AnyStruct?

Function that resolves a metadata view for this fungible token by type.

Parameters:

  • view : The Type of the desired view.

Returns: A structure representing the requested view.