Class Transaction
- java.lang.Object
-
- software.amazon.awssdk.services.managedblockchainquery.model.Transaction
-
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<Transaction.Builder,Transaction>
@Generated("software.amazon.awssdk:codegen") public final class Transaction extends Object implements SdkPojo, Serializable, ToCopyableBuilder<Transaction.Builder,Transaction>
There are two possible types of transactions used for this data type:
-
A Bitcoin transaction is a movement of BTC from one address to another.
-
An Ethereum transaction refers to an action initiated by an externally owned account, which is an account managed by a human, not a contract. For example, if Bob sends Alice 1 ETH, Bob's account must be debited and Alice's must be credited. This state-changing action occurs within a transaction.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceTransaction.Builder
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringblockHash()The block hash is a unique identifier for a block.StringblockNumber()The block number in which the transaction is recorded.static Transaction.Builderbuilder()ConfirmationStatusconfirmationStatus()Specifies whether the transaction has reached Finality.StringconfirmationStatusAsString()Specifies whether the transaction has reached Finality.StringcontractAddress()The blockchain address for the contract.StringcumulativeGasUsed()The amount of gas used up to the specified point in the block.StringeffectiveGasPrice()The effective gas price.booleanequals(Object obj)booleanequalsBySdkFields(Object obj)ExecutionStatusexecutionStatus()Identifies whether the transaction has succeeded or failed.StringexecutionStatusAsString()Identifies whether the transaction has succeeded or failed.Stringfrom()The initiator of the transaction.StringgasUsed()The amount of gas used for the transaction.<T> Optional<T>getValueForField(String fieldName, Class<T> clazz)inthashCode()QueryNetworknetwork()The blockchain network where the transaction occurred.StringnetworkAsString()The blockchain network where the transaction occurred.LongnumberOfTransactions()The number of transactions in the block.List<SdkField<?>>sdkFields()static Class<? extends Transaction.Builder>serializableBuilderClass()StringsignatureR()The signature of the transaction.StringsignatureS()The signature of the transaction.IntegersignatureV()The signature of the transaction.Stringto()The identifier of the transaction.Transaction.BuildertoBuilder()StringtoString()Returns a string representation of this object.StringtransactionFee()The transaction fee.StringtransactionHash()The hash of a transaction.StringtransactionId()The identifier of a Bitcoin transaction.LongtransactionIndex()The index of the transaction within a blockchain.InstanttransactionTimestamp()TheTimestampof the transaction.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
network
public final QueryNetwork network()
The blockchain network where the transaction occurred.
If the service returns an enum value that is not available in the current SDK version,
networkwill returnQueryNetwork.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromnetworkAsString().- Returns:
- The blockchain network where the transaction occurred.
- See Also:
QueryNetwork
-
networkAsString
public final String networkAsString()
The blockchain network where the transaction occurred.
If the service returns an enum value that is not available in the current SDK version,
networkwill returnQueryNetwork.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromnetworkAsString().- Returns:
- The blockchain network where the transaction occurred.
- See Also:
QueryNetwork
-
blockHash
public final String blockHash()
The block hash is a unique identifier for a block. It is a fixed-size string that is calculated by using the information in the block. The block hash is used to verify the integrity of the data in the block.
- Returns:
- The block hash is a unique identifier for a block. It is a fixed-size string that is calculated by using the information in the block. The block hash is used to verify the integrity of the data in the block.
-
transactionHash
public final String transactionHash()
The hash of a transaction. It is generated when a transaction is created.
- Returns:
- The hash of a transaction. It is generated when a transaction is created.
-
blockNumber
public final String blockNumber()
The block number in which the transaction is recorded.
- Returns:
- The block number in which the transaction is recorded.
-
transactionTimestamp
public final Instant transactionTimestamp()
The
Timestampof the transaction.- Returns:
- The
Timestampof the transaction.
-
transactionIndex
public final Long transactionIndex()
The index of the transaction within a blockchain.
- Returns:
- The index of the transaction within a blockchain.
-
numberOfTransactions
public final Long numberOfTransactions()
The number of transactions in the block.
- Returns:
- The number of transactions in the block.
-
to
public final String to()
The identifier of the transaction. It is generated whenever a transaction is verified and added to the blockchain.
- Returns:
- The identifier of the transaction. It is generated whenever a transaction is verified and added to the blockchain.
-
from
public final String from()
The initiator of the transaction. It is either in the form a public key or a contract address.
- Returns:
- The initiator of the transaction. It is either in the form a public key or a contract address.
-
contractAddress
public final String contractAddress()
The blockchain address for the contract.
- Returns:
- The blockchain address for the contract.
-
gasUsed
public final String gasUsed()
The amount of gas used for the transaction.
- Returns:
- The amount of gas used for the transaction.
-
cumulativeGasUsed
public final String cumulativeGasUsed()
The amount of gas used up to the specified point in the block.
- Returns:
- The amount of gas used up to the specified point in the block.
-
effectiveGasPrice
public final String effectiveGasPrice()
The effective gas price.
- Returns:
- The effective gas price.
-
signatureV
public final Integer signatureV()
The signature of the transaction. The Z coordinate of a point V.
- Returns:
- The signature of the transaction. The Z coordinate of a point V.
-
signatureR
public final String signatureR()
The signature of the transaction. The X coordinate of a point R.
- Returns:
- The signature of the transaction. The X coordinate of a point R.
-
signatureS
public final String signatureS()
The signature of the transaction. The Y coordinate of a point S.
- Returns:
- The signature of the transaction. The Y coordinate of a point S.
-
transactionFee
public final String transactionFee()
The transaction fee.
- Returns:
- The transaction fee.
-
transactionId
public final String transactionId()
The identifier of a Bitcoin transaction. It is generated when a transaction is created.
- Returns:
- The identifier of a Bitcoin transaction. It is generated when a transaction is created.
-
confirmationStatus
public final ConfirmationStatus confirmationStatus()
Specifies whether the transaction has reached Finality.
If the service returns an enum value that is not available in the current SDK version,
confirmationStatuswill returnConfirmationStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromconfirmationStatusAsString().- Returns:
- Specifies whether the transaction has reached Finality.
- See Also:
ConfirmationStatus
-
confirmationStatusAsString
public final String confirmationStatusAsString()
Specifies whether the transaction has reached Finality.
If the service returns an enum value that is not available in the current SDK version,
confirmationStatuswill returnConfirmationStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromconfirmationStatusAsString().- Returns:
- Specifies whether the transaction has reached Finality.
- See Also:
ConfirmationStatus
-
executionStatus
public final ExecutionStatus executionStatus()
Identifies whether the transaction has succeeded or failed.
If the service returns an enum value that is not available in the current SDK version,
executionStatuswill returnExecutionStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromexecutionStatusAsString().- Returns:
- Identifies whether the transaction has succeeded or failed.
- See Also:
ExecutionStatus
-
executionStatusAsString
public final String executionStatusAsString()
Identifies whether the transaction has succeeded or failed.
If the service returns an enum value that is not available in the current SDK version,
executionStatuswill returnExecutionStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromexecutionStatusAsString().- Returns:
- Identifies whether the transaction has succeeded or failed.
- See Also:
ExecutionStatus
-
toBuilder
public Transaction.Builder toBuilder()
- Specified by:
toBuilderin interfaceToCopyableBuilder<Transaction.Builder,Transaction>
-
builder
public static Transaction.Builder builder()
-
serializableBuilderClass
public static Class<? extends Transaction.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFieldsin interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
-