SmartContractDataGet()
Retrieve Data of a Contract by Contract Address
Before calling the function make sure you have the Connector object initialized.
Understanding Connector ObjectFunction Call
Field
Type
Description
Address
string
Base58 ed25519 Smart Contract Address
SmartContractDataGet("Input here Base58 Smart Contract Key");
Return value of function: SmartContractDataResult
Example
Connector connect_ = new Connector("95.111.224.219", 9091);
NodeApi.SmartContractDataResult SmartContractData = connect_.SmartContractDataGet("12DHXQ8rzYUawD6VSD6WuVaTQ4uen7fStWsTmZASnDv1");
Console.WriteLine(SmartContractData);
Connect_ = Connector("165.22.212.253:9090")
print(Connect_.SmartContractDataGet("12DHXQ8rzYUawD6VSD6WuVaTQ4uen7fStWsTmZASnDv1"))
var connect_ = new Connector("194.163.152.177", 9091);
connect_.SmartContractDataGet("12DHXQ8rzYUawD6VSD6WuVaTQ4uen7fStWsTmZASnDv1").then((res) => {connect_.Close();console.log(res); });
Return value of function: SmartContractDataResult
Output of Example
Output is printed via ObjectDumper
{SmartContractDataResult}
Status: {APIResponse}
Code: 0
Message: "Success: "
Methods: ...
{SmartContractMethod}
ReturnType: "boolean"
Name: "buyTokens"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "amount"
{SmartContractMethod}
ReturnType: "boolean"
Name: "transferFrom"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "from"
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "to"
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "amount"
{SmartContractMethod}
ReturnType: "java.lang.String"
Name: "getSymbol"
Arguments: ...
{SmartContractMethod}
ReturnType: "void"
Name: "payable"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "amount"
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "currency"
{SmartContractMethod}
ReturnType: "int"
Name: "getDecimal"
Arguments: ...
{SmartContractMethod}
ReturnType: "boolean"
Name: "setFrozen"
Arguments: ...
{SmartContractMethodArgument}
Type: "boolean"
Name: "isFrozen"
{SmartContractMethod}
ReturnType: "java.lang.String"
Name: "totalSupply"
Arguments: ...
{SmartContractMethod}
ReturnType: "java.lang.String"
Name: "balanceOf"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "owner"
{SmartContractMethod}
ReturnType: "java.lang.String"
Name: "allowance"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "owner"
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "spender"
{SmartContractMethod}
ReturnType: "void"
Name: "approve"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "spender"
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "amount"
{SmartContractMethod}
ReturnType: "boolean"
Name: "burn"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "amount"
{SmartContractMethod}
ReturnType: "java.lang.String"
Name: "getName"
Arguments: ...
{SmartContractMethod}
ReturnType: "void"
Name: "register"
Arguments: ...
{SmartContractMethod}
ReturnType: "boolean"
Name: "transfer"
Arguments: ...
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "to"
{SmartContractMethodArgument}
Type: "java.lang.String"
Name: "amount"
Variables: ...
Last updated