Class PaymentFlags


public class PaymentFlags extends TransactionFlags
A set of static TransactionFlags which can be set on Payment transactions.
  • Field Details

    • UNSET

      public static final PaymentFlags UNSET
      Constant PaymentFlags for an unset flag.
    • NO_DIRECT_RIPPLE

      protected static final PaymentFlags NO_DIRECT_RIPPLE
      Constant PaymentFlags for the tfNoDirectRipple flag.
    • PARTIAL_PAYMENT

      protected static final PaymentFlags PARTIAL_PAYMENT
      Constant PaymentFlags for the tfPartialPayment flag.
    • LIMIT_QUALITY

      protected static final PaymentFlags LIMIT_QUALITY
      Constant PaymentFlags for the tfLimitQuality flag.
    • INNER_BATCH_TXN

      public static final PaymentFlags INNER_BATCH_TXN
      Constant PaymentFlags for the tfInnerBatchTxn flag. This flag is used to indicate that a transaction is an inner transaction of a Batch.
      See Also:
      • "https://github.com/XRPLF/XRPL-Standards/tree/master/XLS-0056-batch"
  • Method Details

    • builder

      public static PaymentFlags.Builder builder()
      Create a new PaymentFlags.Builder.
      Returns:
      A new PaymentFlags.Builder.
    • of

      public static PaymentFlags of(long value)
      Construct PaymentFlags with a given value.
      Parameters:
      value - The long-number encoded flags value of this PaymentFlags.
      Returns:
      New PaymentFlags.
    • empty

      public static PaymentFlags empty()
      Construct an empty instance of PaymentFlags. Transactions with empty flags will not be serialized with a Flags field.
      Returns:
      An empty PaymentFlags.
    • tfNoDirectRipple

      public boolean tfNoDirectRipple()
      Do not use the default path; only use paths included in the Payment.paths() field. This is intended to force the transaction to take arbitrage opportunities. Most clients do not need this.
      Returns:
      true if tfNoDirectRipple is set, otherwise false.
    • tfPartialPayment

      public boolean tfPartialPayment()
      If the specified Payment.amount() cannot be sent without spending more than Payment.sendMax(), reduce the received amount instead of failing outright.
      Returns:
      true if tfPartialPayment is set, otherwise false.
      See Also:
      • "https://xrpl.org/partial-payments.html"
    • tfLimitQuality

      public boolean tfLimitQuality()
      Only take paths where all the conversions have an input:output ratio that is equal or better than the ratio of Payment.amount():Payment.sendMax().
      Returns:
      true if tfLimitQuality is set, otherwise false.
    • tfInnerBatchTxn

      public boolean tfInnerBatchTxn()
      Indicates that this transaction is an inner transaction of a Batch transaction.
      Overrides:
      tfInnerBatchTxn in class TransactionFlags
      Returns:
      true if tfInnerBatchTxn is set, otherwise false.
      See Also:
      • "https://github.com/XRPLF/XRPL-Standards/tree/master/XLS-0056-batch"