SimulateNamespace<IDL, I>:MakeInstructionsNamespace<IDL, I, Promise<SimulateResponse>>
The namespace provides functions to simulate transactions for each method
of a program, returning a list of deserialized events and raw program
logs.
One can use this to read data calculated from a program on chain, by
emitting an event in the program and reading the emitted event client side
via the simulate namespace.
The namespace provides functions to simulate transactions for each method of a program, returning a list of deserialized events and raw program logs.
One can use this to read data calculated from a program on chain, by emitting an event in the program and reading the emitted event client side via the
simulatenamespace.Usage
Parameters
args- The positional arguments for the program. The type and number of these arguments depend on the program being used.ctx- [[Context]] non-argument parameters to pass to the method. Always the last parameter in the method call.Example
To simulate the
incrementmethod above,