Package org.stellar.sdk.xdr
Class SorobanTransactionMetaExtV1
java.lang.Object
org.stellar.sdk.xdr.SorobanTransactionMetaExtV1
- All Implemented Interfaces:
XdrElement
SorobanTransactionMetaExtV1's original definition in the XDR file is:
struct SorobanTransactionMetaExtV1
{
ExtensionPoint ext;
// The following are the components of the overall Soroban resource fee
// charged for the transaction.
// The following relation holds:
// `resourceFeeCharged = totalNonRefundableResourceFeeCharged + totalRefundableResourceFeeCharged`
// where `resourceFeeCharged` is the overall fee charged for the
// transaction. Also, `resourceFeeCharged` <= `sorobanData.resourceFee`
// i.e.we never charge more than the declared resource fee.
// The inclusion fee for charged the Soroban transaction can be found using
// the following equation:
// `result.feeCharged = resourceFeeCharged + inclusionFeeCharged`.
// Total amount (in stroops) that has been charged for non-refundable
// Soroban resources.
// Non-refundable resources are charged based on the usage declared in
// the transaction envelope (such as `instructions`, `readBytes` etc.) and
// is charged regardless of the success of the transaction.
int64 totalNonRefundableResourceFeeCharged;
// Total amount (in stroops) that has been charged for refundable
// Soroban resource fees.
// Currently this comprises the rent fee (`rentFeeCharged`) and the
// fee for the events and return value.
// Refundable resources are charged based on the actual resources usage.
// Since currently refundable resources are only used for the successful
// transactions, this will be `0` for failed transactions.
int64 totalRefundableResourceFeeCharged;
// Amount (in stroops) that has been charged for rent.
// This is a part of `totalNonRefundableResourceFeeCharged`.
int64 rentFeeCharged;
};
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class -
Field Summary
Fields inherited from interface org.stellar.sdk.xdr.XdrElement
gson -
Constructor Summary
ConstructorsConstructorDescriptionSorobanTransactionMetaExtV1(ExtensionPoint ext, Int64 totalNonRefundableResourceFeeCharged, Int64 totalRefundableResourceFeeCharged, Int64 rentFeeCharged) Creates a newSorobanTransactionMetaExtV1instance. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()static SorobanTransactionMetaExtV1decode(XdrDataInputStream stream) static SorobanTransactionMetaExtV1decode(XdrDataInputStream stream, int maxDepth) voidencode(XdrDataOutputStream stream) Encodes this value to XDR and writes it to the provided stream.booleanstatic SorobanTransactionMetaExtV1static SorobanTransactionMetaExtV1fromXdrBase64(String xdr) static SorobanTransactionMetaExtV1fromXdrByteArray(byte[] xdr) getExt()Value of theextfield.Value of therentFeeChargedfield.Value of thetotalNonRefundableResourceFeeChargedfield.Value of thetotalRefundableResourceFeeChargedfield.inthashCode()voidsetExt(ExtensionPoint ext) Value of theextfield.voidsetRentFeeCharged(Int64 rentFeeCharged) Value of therentFeeChargedfield.voidsetTotalNonRefundableResourceFeeCharged(Int64 totalNonRefundableResourceFeeCharged) Value of thetotalNonRefundableResourceFeeChargedfield.voidsetTotalRefundableResourceFeeCharged(Int64 totalRefundableResourceFeeCharged) Value of thetotalRefundableResourceFeeChargedfield.toJson()Serializes this value to JSON.toString()Methods inherited from interface org.stellar.sdk.xdr.XdrElement
toXdrBase64, toXdrByteArray
-
Constructor Details
-
SorobanTransactionMetaExtV1
public SorobanTransactionMetaExtV1() -
SorobanTransactionMetaExtV1
public SorobanTransactionMetaExtV1(ExtensionPoint ext, Int64 totalNonRefundableResourceFeeCharged, Int64 totalRefundableResourceFeeCharged, Int64 rentFeeCharged) Creates a newSorobanTransactionMetaExtV1instance.- Parameters:
ext- theextfield valuetotalNonRefundableResourceFeeCharged- thetotalNonRefundableResourceFeeChargedfield valuetotalRefundableResourceFeeCharged- thetotalRefundableResourceFeeChargedfield valuerentFeeCharged- therentFeeChargedfield value
-
-
Method Details
-
encode
Description copied from interface:XdrElementEncodes this value to XDR and writes it to the provided stream.- Specified by:
encodein interfaceXdrElement- Parameters:
stream- the destination XDR output stream- Throws:
IOException- if an I/O error occurs while writing the value
-
decode
public static SorobanTransactionMetaExtV1 decode(XdrDataInputStream stream, int maxDepth) throws IOException - Throws:
IOException
-
decode
- Throws:
IOException
-
fromXdrBase64
- Throws:
IOException
-
fromXdrByteArray
- Throws:
IOException
-
toJson
Description copied from interface:XdrElementSerializes this value to JSON.- Specified by:
toJsonin interfaceXdrElement- Returns:
- the JSON representation of this value
-
fromJson
-
builder
-
toBuilder
-
getExt
Value of theextfield.- Returns:
- the
extfield value
-
getTotalNonRefundableResourceFeeCharged
Value of thetotalNonRefundableResourceFeeChargedfield.- Returns:
- the
totalNonRefundableResourceFeeChargedfield value
-
getTotalRefundableResourceFeeCharged
Value of thetotalRefundableResourceFeeChargedfield.- Returns:
- the
totalRefundableResourceFeeChargedfield value
-
getRentFeeCharged
Value of therentFeeChargedfield.- Returns:
- the
rentFeeChargedfield value
-
setExt
Value of theextfield.- Parameters:
ext- theextfield value
-
setTotalNonRefundableResourceFeeCharged
Value of thetotalNonRefundableResourceFeeChargedfield.- Parameters:
totalNonRefundableResourceFeeCharged- thetotalNonRefundableResourceFeeChargedfield value
-
setTotalRefundableResourceFeeCharged
Value of thetotalRefundableResourceFeeChargedfield.- Parameters:
totalRefundableResourceFeeCharged- thetotalRefundableResourceFeeChargedfield value
-
setRentFeeCharged
Value of therentFeeChargedfield.- Parameters:
rentFeeCharged- therentFeeChargedfield value
-
equals
-
hashCode
public int hashCode() -
toString
-