PolymeshTransaction
Last updated
Was this helpful?
Last updated
Was this helpful?
Wrapper class for a Polymesh Transaction
▪ Args: unknown[]
▪ Values: unknown[]
‹Args, Values›
↳ PolymeshTransaction
Optional
blockHash• blockHash? : undefined | string
hash of the block where this transaction resides (status: Succeeded
, Failed
)
Protected
contextOptional
errorstores errors thrown while running the transaction (status: Failed
, Aborted
)
• inputArgs: MapMaybePostTransactionValue‹Args›
arguments for the transaction. Available after the transaction starts running (may be Post Transaction Values from a previous transaction in the queue that haven't resolved yet)
• isCritical: boolean
whether this tx failing makes the entire tx queue fail or not
• paidByThirdParty: boolean
whether the fees for this tx are paid by a third party. For example, when accepting/rejecting a request to join an Identity, fees are paid by the Identity that sent the request
Optional
receipt• receipt? : ISubmittableResult
stores the transaction receipt (if successful)
current status of the transaction
Optional
txHash• txHash? : undefined | string
transaction hash (status: Running
, Succeeded
, Failed
)
• get args(): Args
Arguments for the transaction
Returns: Args
• get tag(): TxTag
type of transaction represented by this instance for display purposes. If the transaction isn't defined at design time, the tag won't be set (will be empty string) until the transaction is about to be run
Returns: TxTag
Get all (protocol and gas) fees associated with this transaction. Returns null if the transaction is not ready yet (this can happen if it depends on the execution of a previous transaction in the queue)
▸ onStatusChange(listener
: function): function
Subscribe to status changes
Parameters:
▪ listener: function
callback function that will be called whenever the status changes
▸ (transaction
: this): void
Parameters:
Name
Type
transaction
this
Returns: function
unsubscribe function
▸ (): void
▸ run(): Promise‹void›
Run the poly transaction and update the transaction status
Returns: Promise‹void›
Inherited from .
Defined in
• context:
Inherited from .
Defined in
• error? :
Inherited from .
Defined in
Defined in
Inherited from .
Defined in
Inherited from .
Defined in
Inherited from .
Defined in
• status: = TransactionStatus.Idle
Inherited from .
Defined in
Inherited from .
Defined in
Defined in
Inherited from .
Defined in
▸ getFees(): Promise‹ | null›
Inherited from .
Defined in
Returns: Promise‹ | null›
Inherited from .
Defined in
Inherited from .
Defined in