Skip to main content

TransactionContext

For the complete documentation index, see llms.txt

@midnight/ledger v8.0.3


@midnight/ledger / TransactionContext

Class: TransactionContext

The context against which a transaction is run.

Constructors​

Constructor​

new TransactionContext(
ref_state,
block_context,
whitelist?): TransactionContext;

Parameters​

ref_state​

LedgerState

A past ledger state that is used as a reference point for 'static' data.

block_context​

BlockContext

Information about the block this transaction is, or will be, contained in.

whitelist?​

Set<string>

A list of contracts that are being tracked, or undefined to track all contracts.

Returns​

TransactionContext

Methods​

toString()​

toString(compact?): string;

Parameters​

compact?​

boolean

Returns​

string