Class: EvmInternalTransaction
moralis-monorepo / @moralisweb3/common-evm-utils / EvmInternalTransaction
Class: EvmInternalTransaction
@moralisweb3/common-evm-utils.EvmInternalTransaction
The EvmTranaction is a representation of a published transaction.
Use this class any time you work with a transaction.
Implements
MoralisDataObject
Table of contents
Methods
Accessors
Constructors
Methods
create
▸ Static
create(data
): EvmInternalTransaction
Create a new instance of EvmInternalTransaction from any valid transaction input
Example
const transaction = EvmInternalTransaction.create(data);
Parameters
Name | Type | Description |
---|---|---|
data | EvmInternalTransactionish | the EvmInternalTransactionish type |
Returns
equals
▸ Static
equals(dataA
, dataB
): boolean
Check the equality between two Evm internal transactions
Example
EvmInternalTransaction.equals(dataA, dataB)
Parameters
Name | Type | Description |
---|---|---|
dataA | EvmInternalTransactionish | The first transaction |
dataB | EvmInternalTransactionish | The second transaction |
Returns
boolean
parse
▸ Static
parse(data
): EvmInternalTransactionData
Parameters
Name | Type |
---|---|
data | EvmInternalTransactionInput |
Returns
equals
▸ equals(data
): boolean
Checks the equality of the current transaction with another evm transaction
Example
transaction.equals(data)
Parameters
Name | Type | Description |
---|---|---|
data | EvmInternalTransactionish | the transaction to compare with |
Returns
boolean
Implementation of
MoralisDataObject.equals
format
▸ format(): Object
Deprecated
This method will be removed soon. To format the value, use one of the properties.
Returns
Object
Name | Type |
---|---|
blockHash | string |
blockNumber | string |
chain | string |
from | string |
gas | string |
gasUsed | string |
input | string |
output | string |
to | string |
transactionHash | string |
type | string |
value | string |
Implementation of
MoralisDataObject.format
toJSON
▸ toJSON(): Object
Returns
Object
Name | Type |
---|---|
blockHash | string |
blockNumber | string |
chain | string |
from | string |
gas | string |
gasUsed | string |
input | string |
output | string |
to | string |
transactionHash | string |
type | string |
value | string |
Implementation of
MoralisDataObject.toJSON
Accessors
blockHash
• get
blockHash(): string
Returns
string
blockNumber
• get
blockNumber(): BigNumber
Returns
BigNumber
chain
• get
chain(): EvmChain
Returns
from
• get
from(): EvmAddress
Returns
gas
• get
gas(): BigNumber
Returns
BigNumber
gasUsed
• get
gasUsed(): BigNumber
Returns
BigNumber
input
• get
input(): string
Returns
string
output
• get
output(): string
Returns
string
result
• get
result(): EvmInternalTransactionData
Returns
to
• get
to(): EvmAddress
Returns
transactionHash
• get
transactionHash(): string
Returns
string
type
• get
type(): string
Returns
string
value
• get
value(): BigNumber
Returns
BigNumber
Constructors
constructor
• new EvmInternalTransaction(data
)
Parameters
Name | Type |
---|---|
data | EvmInternalTransactionInput |