public abstract class Payload extends Object
Constructor and Description |
---|
Payload() |
Modifier and Type | Method and Description |
---|---|
static UInt64 |
calculateEnergyCost(int noOfSignatures,
int payloadSize,
UInt64 transactionSpecificCost)
Calculate the total energy cost of a transaction.
|
boolean |
equals(Object obj) |
byte[] |
getBytes()
Get the serialized payload.
|
protected abstract byte[] |
getRawPayloadBytes()
This must return the raw payload i.e., the
payload only.
|
abstract TransactionType |
getTransactionType() |
public final byte[] getBytes()
TransactionType
public static UInt64 calculateEnergyCost(int noOfSignatures, int payloadSize, UInt64 transactionSpecificCost)
noOfSignatures
- number of signatures in the transactionpayloadSize
- size of the payloadtransactionSpecificCost
- cost of the specific transaction type.public abstract TransactionType getTransactionType()
protected abstract byte[] getRawPayloadBytes()
getBytes()
Copyright © 2025. All rights reserved.