Search code examples
blockchainsmartcontractswavesplatformride

What does the parameter "i" represent in the callable functions in Ride4dApps?


I'm totally new to Ride4dApps and while trying to write a callable function I did not understand what the parameter i stands for here @Callable(i)?


Solution

  • You need to use @callable(i) to be able to access the data for an invoked function.

    The parameter i is of type Invocation and basically Invocation is a data structure of:

    caller: Address.
    payment: Payment|Un, where Payment consist of amount: Long and assetId: ByteVector | Unit.