Table of Contents

Class ContractClient

Namespace
Aptos
Assembly
Aptos.dll
public class ContractClient
Inheritance
ContractClient
Inherited Members

Constructors

ContractClient(AptosClient)

public ContractClient(AptosClient client)

Parameters

client AptosClient

Methods

GetEntryFunctionAbi(string, string, string, ulong?)

public Task<EntryFunctionAbi> GetEntryFunctionAbi(string moduleAddress, string moduleName, string functionName, ulong? ledgerVersion = null)

Parameters

moduleAddress string
moduleName string
functionName string
ledgerVersion ulong?

Returns

Task<EntryFunctionAbi>

GetFunctionAbi(string, string, string)

public Task<MoveFunction?> GetFunctionAbi(string moduleAddress, string moduleName, string functionName)

Parameters

moduleAddress string
moduleName string
functionName string

Returns

Task<MoveFunction>

GetViewFunctionAbi(string, string, string)

public Task<ViewFunctionAbi> GetViewFunctionAbi(string moduleAddress, string moduleName, string functionName)

Parameters

moduleAddress string
moduleName string
functionName string

Returns

Task<ViewFunctionAbi>

View(GenerateViewFunctionPayloadData, ulong?)

Calls the Move view function with the given payload and returns the result.

public Task<List<object>> View(GenerateViewFunctionPayloadData data, ulong? ledgerVersion = null)

Parameters

data GenerateViewFunctionPayloadData

The payload of the view function to call.

ledgerVersion ulong?

The ledger version to use for the view function call.

Returns

Task<List<object>>

An array of Move values representing the result of the view function.

View<T>(GenerateViewFunctionPayloadData, ulong?)

Calls the Move view function with the given payload and returns the result.

public Task<T> View<T>(GenerateViewFunctionPayloadData data, ulong? ledgerVersion = null) where T : class

Parameters

data GenerateViewFunctionPayloadData

The payload of the view function to call.

ledgerVersion ulong?

The ledger version to use for the view function call.

Returns

Task<T>

An instance of the specified type T representing the result of the view function.

Type Parameters

T

The type of the result of the view function.