Class TransactionMetaV4

java.lang.Object
org.stellar.sdk.xdr.TransactionMetaV4
All Implemented Interfaces:
XdrElement

public class TransactionMetaV4 extends Object implements XdrElement
TransactionMetaV4's original definition in the XDR file is:
 struct TransactionMetaV4
 {
     ExtensionPoint ext;

     LedgerEntryChanges txChangesBefore;  // tx level changes before operations
                                          // are applied if any
     OperationMetaV2 operations<>;        // meta for each operation
     LedgerEntryChanges txChangesAfter;   // tx level changes after operations are
                                          // applied if any
     SorobanTransactionMetaV2* sorobanMeta; // Soroban-specific meta (only for
                                            // Soroban transactions).

     TransactionEvent events<>; // Used for transaction-level events (like fee payment)
     DiagnosticEvent diagnosticEvents<>; // Used for all diagnostic information
 };
 
  • Constructor Details

    • TransactionMetaV4

      public TransactionMetaV4()
    • TransactionMetaV4

      public TransactionMetaV4(ExtensionPoint ext, LedgerEntryChanges txChangesBefore, OperationMetaV2[] operations, LedgerEntryChanges txChangesAfter, SorobanTransactionMetaV2 sorobanMeta, TransactionEvent[] events, DiagnosticEvent[] diagnosticEvents)
      Creates a new TransactionMetaV4 instance.
      Parameters:
      ext - the ext field value
      txChangesBefore - the txChangesBefore field value
      operations - the operations field value
      txChangesAfter - the txChangesAfter field value
      sorobanMeta - the sorobanMeta field value
      events - the events field value
      diagnosticEvents - the diagnosticEvents field value
  • Method Details

    • encode

      public void encode(XdrDataOutputStream stream) throws IOException
      Description copied from interface: XdrElement
      Encodes this value to XDR and writes it to the provided stream.
      Specified by:
      encode in interface XdrElement
      Parameters:
      stream - the destination XDR output stream
      Throws:
      IOException - if an I/O error occurs while writing the value
    • decode

      public static TransactionMetaV4 decode(XdrDataInputStream stream, int maxDepth) throws IOException
      Throws:
      IOException
    • decode

      public static TransactionMetaV4 decode(XdrDataInputStream stream) throws IOException
      Throws:
      IOException
    • fromXdrBase64

      public static TransactionMetaV4 fromXdrBase64(String xdr) throws IOException
      Throws:
      IOException
    • fromXdrByteArray

      public static TransactionMetaV4 fromXdrByteArray(byte[] xdr) throws IOException
      Throws:
      IOException
    • toJson

      public String toJson()
      Description copied from interface: XdrElement
      Serializes this value to JSON.
      Specified by:
      toJson in interface XdrElement
      Returns:
      the JSON representation of this value
    • fromJson

      public static TransactionMetaV4 fromJson(String json)
    • builder

    • toBuilder

    • getExt

      public ExtensionPoint getExt()
      Value of the ext field.
      Returns:
      the ext field value
    • getTxChangesBefore

      public LedgerEntryChanges getTxChangesBefore()
      Value of the txChangesBefore field.
      Returns:
      the txChangesBefore field value
    • getOperations

      public OperationMetaV2[] getOperations()
      Value of the operations field.
      Returns:
      the operations field value
    • getTxChangesAfter

      public LedgerEntryChanges getTxChangesAfter()
      Value of the txChangesAfter field.
      Returns:
      the txChangesAfter field value
    • getSorobanMeta

      public SorobanTransactionMetaV2 getSorobanMeta()
      Value of the sorobanMeta field.
      Returns:
      the sorobanMeta field value
    • getEvents

      public TransactionEvent[] getEvents()
      Value of the events field.
      Returns:
      the events field value
    • getDiagnosticEvents

      public DiagnosticEvent[] getDiagnosticEvents()
      Value of the diagnosticEvents field.
      Returns:
      the diagnosticEvents field value
    • setExt

      public void setExt(ExtensionPoint ext)
      Value of the ext field.
      Parameters:
      ext - the ext field value
    • setTxChangesBefore

      public void setTxChangesBefore(LedgerEntryChanges txChangesBefore)
      Value of the txChangesBefore field.
      Parameters:
      txChangesBefore - the txChangesBefore field value
    • setOperations

      public void setOperations(OperationMetaV2[] operations)
      Value of the operations field.
      Parameters:
      operations - the operations field value
    • setTxChangesAfter

      public void setTxChangesAfter(LedgerEntryChanges txChangesAfter)
      Value of the txChangesAfter field.
      Parameters:
      txChangesAfter - the txChangesAfter field value
    • setSorobanMeta

      public void setSorobanMeta(SorobanTransactionMetaV2 sorobanMeta)
      Value of the sorobanMeta field.
      Parameters:
      sorobanMeta - the sorobanMeta field value
    • setEvents

      public void setEvents(TransactionEvent[] events)
      Value of the events field.
      Parameters:
      events - the events field value
    • setDiagnosticEvents

      public void setDiagnosticEvents(DiagnosticEvent[] diagnosticEvents)
      Value of the diagnosticEvents field.
      Parameters:
      diagnosticEvents - the diagnosticEvents field value
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object