Show / Hide Table of Contents

Class ContractCallResultData

Provides services to decode smart contract ABI data into .net primitives. Typically represents data returned from a smart contract invocation.

Inheritance
Object
ContractCallResultData
Inherited Members
Object.Equals(Object)
Object.Equals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Object.ReferenceEquals(Object, Object)
Object.ToString()
Namespace: Hashgraph
Assembly: Hashgraph.dll
Syntax
public class ContractCallResultData

Properties

| Improve this Doc View Source

Data

A Readonly copy of the data in raw ABI format.

Declaration
public ReadOnlyMemory<byte> Data { get; }
Property Value
Type Description
ReadOnlyMemory<Byte>
| Improve this Doc View Source

Size

The size in bytes of the data (in ABI format) returned from the function call.

Declaration
public int Size { get; }
Property Value
Type Description
Int32

Methods

| Improve this Doc View Source

As<T>()

Retrieves the first value returned from the contract cast to the desired native type.

Declaration
public T As<T>()
Returns
Type Description
T

The value of the first argument decoded from the ABI results.

Type Parameters
Name Description
T

Type of the first argument, must be known to the caller.

| Improve this Doc View Source

As<T1, T2>()

Retrieves the first and second values from the contract function result cast to the desired types.

Declaration
public (T1, T2) As<T1, T2>()
Returns
Type Description
(T1, T2)<T1, T2>

A tuple of the first two arguments decoded from the contract function ABI results.

Type Parameters
Name Description
T1

Type of the first argument, must be known to the caller.

T2

Type of the second argument, must be known to the caller.

| Improve this Doc View Source

As<T1, T2, T3>()

Retrieves the three values from the contract function result cast to the desired types.

Declaration
public (T1, T2, T3) As<T1, T2, T3>()
Returns
Type Description
(T1, T2, T3)<T1, T2, T3>

A tuple of the first three arguments decoded from the contract function ABI results.

Type Parameters
Name Description
T1

Type of the first argument, must be known to the caller.

T2

Type of the second argument, must be known to the caller.

T3

Type of the third argument, must be known to the caller.

| Improve this Doc View Source

As<T1, T2, T3, T4>()

Retrieves the four values from the contract function result cast to the desired types.

Declaration
public (T1, T2, T3, T4) As<T1, T2, T3, T4>()
Returns
Type Description
(T1, T2, T3, T4)<T1, T2, T3, T4>

A tuple of the first four arguments decoded from the contract function ABI results.

Type Parameters
Name Description
T1

Type of the first argument, must be known to the caller.

T2

Type of the second argument, must be known to the caller.

T3

Type of the third argument, must be known to the caller.

T4

Type of the fourth argument, must be known to the caller.

| Improve this Doc View Source

GetAll(Type[])

Retrieves an arbitrary number of values decoded from the contract return data.

Declaration
public object[] GetAll(params Type[] types)
Parameters
Type Name Description
Type[] types

An array of native types that should be returned. Must be known by the caller.

Returns
Type Description
Object[]

An array of objects (which may be boxed) of the decoded parameters of the types desired.

  • Improve this Doc
  • View Source
In This Article
Back to top .NET Client Library for Hedera Hashgraph