Properties
Private
Readonly
connection
Methods
Private
fetch
- fetch(contractId, blockQuery): Promise<{
blockHash: string;
blockHeight: number;
blockTimestamp: number;
contractCode: string;
contractState: ContractState;
}> Parameters
- contractId: string
- blockQuery: BlockReference
Returns Promise<{
blockHash: string;
blockHeight: number;
blockTimestamp: number;
contractCode: string;
contractState: ContractState;
}>
Private
fetchContractCode
- fetchContractCode(contractId, blockQuery): Promise<string>
Parameters
- contractId: string
- blockQuery: BlockReference
Returns Promise<string>
Private
fetchContractState
- fetchContractState(contractId, blockQuery): Promise<ContractState>
Parameters
- contractId: string
- blockQuery: BlockReference
Private
loadOrFetch
- loadOrFetch(contractId, blockQuery): Promise<StorageData>
Parameters
- contractId: string
- blockQuery: BlockReference
viewFunction
- viewFunction(options): Promise<any>
Parameters
- options: ViewFunctionCallOptions
Returns Promise<any>
- A promise that resolves to the result of the view function.
Calls a view function on a contract, fetching the contract code and state if needed.