java.lang.Object
tech.deplant.java4ever.binding.Tvm

public class Tvm extends Object
  • Constructor Details

    • Tvm

      public Tvm()
  • Method Details

    • runExecutor

      public static CompletableFuture<Tvm.ResultOfRunExecutor> runExecutor(@NonNull @NonNull Context context, @NonNull @NonNull String message, @NonNull @NonNull Tvm.AccountForExecutor account, Tvm.ExecutionOptions executionOptions, Abi.ABI abi, Boolean skipTransactionCheck, Boc.BocCacheType bocCache, Boolean returnUpdatedAccount)
      Emulates all the phases of contract execution locally
      Parameters:
      message - Input message BOC. Must be encoded as base64.
      account - Account to run on executor
      executionOptions - Execution options.
      abi - Contract ABI for decoding output messages
      skipTransactionCheck - Skip transaction check flag
      bocCache - Cache type to put the result. The BOC itself returned if no cache type provided
      returnUpdatedAccount - Return updated account flag. Empty string is returned if the flag is `false`
    • runTvm

      public static CompletableFuture<Tvm.ResultOfRunTvm> runTvm(@NonNull @NonNull Context context, @NonNull @NonNull String message, @NonNull @NonNull String account, Tvm.ExecutionOptions executionOptions, Abi.ABI abi, Boc.BocCacheType bocCache, Boolean returnUpdatedAccount)
      Executes get-methods of ABI-compatible contracts
      Parameters:
      message - Input message BOC. Must be encoded as base64.
      account - Account BOC. Must be encoded as base64.
      executionOptions - Execution options.
      abi - Contract ABI for decoding output messages
      bocCache - Cache type to put the result. The BOC itself returned if no cache type provided
      returnUpdatedAccount - Return updated account flag. Empty string is returned if the flag is `false`
    • runGet

      public static CompletableFuture<Tvm.ResultOfRunGet> runGet(@NonNull @NonNull Context context, @NonNull @NonNull String account, @NonNull @NonNull String functionName, Map<String,Object> input, Tvm.ExecutionOptions executionOptions, Boolean tupleListAsArray)
      Executes a get-method of FIFT contract
      Parameters:
      account - Account BOC in `base64`
      functionName - Function name
      input - Input parameters
      executionOptions - Execution options
      tupleListAsArray - Convert lists based on nested tuples in the **result** into plain arrays. Default is `false`. Input parameters may use any of lists representationsIf you receive this error on Web: "Runtime error. Unreachable code should not be executed...",set this flag to true.This may happen, for example, when elector contract contains too many participants