1#ifndef IOTEX_XRC20_CONTRACT_H
2#define IOTEX_XRC20_CONTRACT_H
4#include "contract/contract.h"
5#include "IoTeXConstants.h"
7#define IOTEX_CONTRACT_ENCODED_FUNCTIONSELECTOR_SIZE 4
8#define IOTEX_CONTRACT_ENCODED_TOTALSUPPLY_SIZE 36
9#define IOTEX_CONTRACT_ENCODED_TRANSFER_SIZE 68
32 uint8_t data[IOTEX_CONTRACT_ENCODED_TOTALSUPPLY_SIZE]);
43 uint8_t data[IOTEX_CONTRACT_ENCODED_TRANSFER_SIZE]);
Definition: xrc20Contract.h:14
static void generateCallDataForBalanceOf(uint8_t address[ETH_ADDRESS_SIZE], uint8_t data[IOTEX_CONTRACT_ENCODED_TOTALSUPPLY_SIZE])
Generates the Ethereum ABI encoded data for calling the balanceOf() function of a XRC20 token.
Definition: xrc20Contract.cpp:12
static void generateCallDataForTransfer(uint8_t to[ETH_ADDRESS_SIZE], uint64_t value, uint8_t data[IOTEX_CONTRACT_ENCODED_TRANSFER_SIZE])
Generates the Ethereum ABI encoded data for calling the transfer() function of a XRC20 token.
Definition: xrc20Contract.cpp:22
static void generateCallDataForTotalSupply(uint8_t data[4])
Generates the Ethereum ABI encoded data for calling the totalSupply() function of a XRC20 token.
Definition: xrc20Contract.cpp:6