Class ImmutablePaymentChannelClaim
- java.lang.Object
-
- org.xrpl.xrpl4j.model.transactions.ImmutablePaymentChannelClaim
-
- All Implemented Interfaces:
PaymentChannelClaim
,Transaction
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutablePaymentChannelClaim extends Object implements PaymentChannelClaim
Immutable implementation ofPaymentChannelClaim
.Use the builder to create immutable instances:
ImmutablePaymentChannelClaim.builder()
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ImmutablePaymentChannelClaim.Builder
Builds instances of typeImmutablePaymentChannelClaim
.
-
Field Summary
-
Fields inherited from interface org.xrpl.xrpl4j.model.transactions.Transaction
RIPPLE_EPOCH, typeMap
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Address
account()
The uniqueAddress
of the account that initiated this transaction.Optional<Hash256>
accountTransactionId()
Hash value identifying another transaction.Optional<XrpCurrencyAmount>
amount()
The amount of XRP, in drops, authorized by thesignature()
.Optional<XrpCurrencyAmount>
balance()
Total amount of XRP, in drops, delivered by this channel after processing this claim.static ImmutablePaymentChannelClaim.Builder
builder()
Creates a builder forImmutablePaymentChannelClaim
.Hash256
channel()
The unique ID of the channel, as aHash256
.Optional<com.google.common.primitives.UnsignedLong>
closeDate()
Deprecated.This field will be removed in favor ofTransactionResult.closeDate()
;static ImmutablePaymentChannelClaim
copyOf(PaymentChannelClaim instance)
Creates an immutable copy of aPaymentChannelClaim
value.boolean
equals(Object another)
This instance is equal to all instances ofImmutablePaymentChannelClaim
that have equal attribute values.XrpCurrencyAmount
fee()
TheString
representation of an integer amount of XRP, in drops, to be destroyed as a cost for distributing this Payment transaction to the network.Flags.PaymentChannelClaimFlags
flags()
Bit-map of booleanFlags.PaymentChannelClaimFlags
to set for this transaction.Optional<Hash256>
hash()
Deprecated.This field will be removed in a future release.int
hashCode()
Computes a hash code from attributes:account
,fee
,sequence
,accountTransactionId
,lastLedgerSequence
,memos
,signers
,sourceTag
,signingPublicKey
,transactionSignature
,closeDate
,hash
,ledgerIndex
,flags
,channel
,balance
,amount
,signature
,publicKey
.Optional<com.google.common.primitives.UnsignedInteger>
lastLedgerSequence()
Highest ledger index this transaction can appear in.Optional<LedgerIndex>
ledgerIndex()
Deprecated.This field will be removed in a future release.com.google.common.collect.ImmutableList<MemoWrapper>
memos()
Additional arbitrary information used to identify thisTransaction
.Optional<String>
publicKey()
The public key used for thesignature()
, as hexadecimal.com.google.common.primitives.UnsignedInteger
sequence()
The sequence number of the account submitting theTransaction
.Optional<String>
signature()
The signature of this claim, in hexadecimal form.com.google.common.collect.ImmutableList<SignerWrapper>
signers()
Array ofSignerWrapper
s that represent a multi-signature which authorizes thisTransaction
.Optional<String>
signingPublicKey()
Hex representation of the public key that corresponds to the private key used to sign this transaction.Optional<com.google.common.primitives.UnsignedInteger>
sourceTag()
ArbitraryUnsignedInteger
used to identify the reason for thisTransaction
, or a sender on whose behalf thisTransaction
is made.String
toString()
Prints the immutable valuePaymentChannelClaim
with attribute values.Optional<String>
transactionSignature()
The signature that verifies this transaction as originating from the account it says it is from.ImmutablePaymentChannelClaim
withAccount(Address value)
Copy the current immutable object by setting a value for theaccount
attribute.ImmutablePaymentChannelClaim
withAccountTransactionId(Optional<? extends Hash256> optional)
Copy the current immutable object by setting an optional value for theaccountTransactionId
attribute.ImmutablePaymentChannelClaim
withAccountTransactionId(Hash256 value)
Copy the current immutable object by setting a present value for the optionalaccountTransactionId
attribute.ImmutablePaymentChannelClaim
withAmount(Optional<? extends XrpCurrencyAmount> optional)
Copy the current immutable object by setting an optional value for theamount
attribute.ImmutablePaymentChannelClaim
withAmount(XrpCurrencyAmount value)
Copy the current immutable object by setting a present value for the optionalamount
attribute.ImmutablePaymentChannelClaim
withBalance(Optional<? extends XrpCurrencyAmount> optional)
Copy the current immutable object by setting an optional value for thebalance
attribute.ImmutablePaymentChannelClaim
withBalance(XrpCurrencyAmount value)
Copy the current immutable object by setting a present value for the optionalbalance
attribute.ImmutablePaymentChannelClaim
withChannel(Hash256 value)
Copy the current immutable object by setting a value for thechannel
attribute.ImmutablePaymentChannelClaim
withCloseDate(com.google.common.primitives.UnsignedLong value)
Deprecated.ImmutablePaymentChannelClaim
withCloseDate(Optional<? extends com.google.common.primitives.UnsignedLong> optional)
Deprecated.ImmutablePaymentChannelClaim
withFee(XrpCurrencyAmount value)
Copy the current immutable object by setting a value for thefee
attribute.ImmutablePaymentChannelClaim
withFlags(Flags.PaymentChannelClaimFlags value)
Copy the current immutable object by setting a value for theflags
attribute.ImmutablePaymentChannelClaim
withHash(Optional<? extends Hash256> optional)
Deprecated.ImmutablePaymentChannelClaim
withHash(Hash256 value)
Deprecated.ImmutablePaymentChannelClaim
withLastLedgerSequence(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionallastLedgerSequence
attribute.ImmutablePaymentChannelClaim
withLastLedgerSequence(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thelastLedgerSequence
attribute.ImmutablePaymentChannelClaim
withLedgerIndex(Optional<? extends LedgerIndex> optional)
Deprecated.ImmutablePaymentChannelClaim
withLedgerIndex(LedgerIndex value)
Deprecated.ImmutablePaymentChannelClaim
withMemos(Iterable<? extends MemoWrapper> elements)
Copy the current immutable object with elements that replace the content ofmemos
.ImmutablePaymentChannelClaim
withMemos(MemoWrapper... elements)
Copy the current immutable object with elements that replace the content ofmemos
.ImmutablePaymentChannelClaim
withPublicKey(String value)
Copy the current immutable object by setting a present value for the optionalpublicKey
attribute.ImmutablePaymentChannelClaim
withPublicKey(Optional<String> optional)
Copy the current immutable object by setting an optional value for thepublicKey
attribute.ImmutablePaymentChannelClaim
withSequence(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a value for thesequence
attribute.ImmutablePaymentChannelClaim
withSignature(String value)
Copy the current immutable object by setting a present value for the optionalsignature
attribute.ImmutablePaymentChannelClaim
withSignature(Optional<String> optional)
Copy the current immutable object by setting an optional value for thesignature
attribute.ImmutablePaymentChannelClaim
withSigners(Iterable<? extends SignerWrapper> elements)
Copy the current immutable object with elements that replace the content ofsigners
.ImmutablePaymentChannelClaim
withSigners(SignerWrapper... elements)
Copy the current immutable object with elements that replace the content ofsigners
.ImmutablePaymentChannelClaim
withSigningPublicKey(String value)
Copy the current immutable object by setting a present value for the optionalsigningPublicKey
attribute.ImmutablePaymentChannelClaim
withSigningPublicKey(Optional<String> optional)
Copy the current immutable object by setting an optional value for thesigningPublicKey
attribute.ImmutablePaymentChannelClaim
withSourceTag(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionalsourceTag
attribute.ImmutablePaymentChannelClaim
withSourceTag(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thesourceTag
attribute.ImmutablePaymentChannelClaim
withTransactionSignature(String value)
Copy the current immutable object by setting a present value for the optionaltransactionSignature
attribute.ImmutablePaymentChannelClaim
withTransactionSignature(Optional<String> optional)
Copy the current immutable object by setting an optional value for thetransactionSignature
attribute.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.xrpl.xrpl4j.model.transactions.Transaction
closeDateHuman, transactionType
-
-
-
-
Method Detail
-
account
public Address account()
The uniqueAddress
of the account that initiated this transaction.- Specified by:
account
in interfaceTransaction
- Returns:
- The
Address
of the account submitting this transaction.
-
fee
public XrpCurrencyAmount fee()
TheString
representation of an integer amount of XRP, in drops, to be destroyed as a cost for distributing this Payment transaction to the network.This field is auto-fillable
- Specified by:
fee
in interfaceTransaction
- Returns:
- An
XrpCurrencyAmount
representing the transaction cost. - See Also:
- "https://xrpl.org/transaction-common-fields.html#auto-fillable-fields"
-
sequence
public com.google.common.primitives.UnsignedInteger sequence()
The sequence number of the account submitting theTransaction
. ATransaction
is only valid if the Sequence number is exactly 1 greater than the previous transaction from the same account.This field is auto-fillable
- Specified by:
sequence
in interfaceTransaction
- Returns:
- An
UnsignedInteger
representing the sequence of the transaction. - See Also:
- "https://xrpl.org/transaction-common-fields.html#auto-fillable-fields"
-
accountTransactionId
public Optional<Hash256> accountTransactionId()
Hash value identifying another transaction. If provided, thisTransaction
is only valid if the sending account's previously-sent transaction matches the provided hash.- Specified by:
accountTransactionId
in interfaceTransaction
- Returns:
- An
Optional
of typeHash256
containing the account transaction ID.
-
lastLedgerSequence
public Optional<com.google.common.primitives.UnsignedInteger> lastLedgerSequence()
Highest ledger index this transaction can appear in. Specifying this field places a strict upper limit on how long the transaction can wait to be validated or rejected.- Specified by:
lastLedgerSequence
in interfaceTransaction
- Returns:
- An
Optional
of typeUnsignedInteger
representing the last ledger sequence.
-
memos
public com.google.common.collect.ImmutableList<MemoWrapper> memos()
Additional arbitrary information used to identify thisTransaction
.- Specified by:
memos
in interfaceTransaction
- Returns:
- A
List
ofMemoWrapper
s.
-
signers
public com.google.common.collect.ImmutableList<SignerWrapper> signers()
Array ofSignerWrapper
s that represent a multi-signature which authorizes thisTransaction
.- Specified by:
signers
in interfaceTransaction
- Returns:
- A
List
ofSignerWrapper
s.
-
sourceTag
public Optional<com.google.common.primitives.UnsignedInteger> sourceTag()
ArbitraryUnsignedInteger
used to identify the reason for thisTransaction
, or a sender on whose behalf thisTransaction
is made.- Specified by:
sourceTag
in interfaceTransaction
- Returns:
- An
Optional
UnsignedInteger
representing the source account's tag.
-
signingPublicKey
public Optional<String> signingPublicKey()
Hex representation of the public key that corresponds to the private key used to sign this transaction. If an empty string, indicates a multi-signature is present in theTransaction.signers()
field instead.This field is automatically added when signing this
Transaction
.- Specified by:
signingPublicKey
in interfaceTransaction
- Returns:
- An
Optional
String
containing the public key of the account submitting the transaction.
-
transactionSignature
public Optional<String> transactionSignature()
The signature that verifies this transaction as originating from the account it says it is from.This field is automatically added when signing this
Transaction
.- Specified by:
transactionSignature
in interfaceTransaction
- Returns:
- An
Optional
String
containing the transaction signature.
-
closeDate
@Deprecated public Optional<com.google.common.primitives.UnsignedLong> closeDate()
Deprecated.This field will be removed in favor ofTransactionResult.closeDate()
;The approximate close time (using Ripple Epoch) of the ledger containing this transaction. This is an undocumented field.- Specified by:
closeDate
in interfaceTransaction
- Returns:
- An optionally-present
UnsignedLong
.
-
hash
@Deprecated public Optional<Hash256> hash()
Deprecated.This field will be removed in a future release. Instead, useAccountTransactionsTransaction.hash()
found inAccountTransactionsResult.transactions()
.The transaction hash of this transaction. Only present in responses toaccount_tx
rippled calls.- Specified by:
hash
in interfaceTransaction
- Returns:
- An optionally present
Hash256
containing the transaction hash.
-
ledgerIndex
@Deprecated public Optional<LedgerIndex> ledgerIndex()
Deprecated.This field will be removed in a future release. Instead, useAccountTransactionsTransaction.ledgerIndex()
found inAccountTransactionsResult.transactions()
.The index of the ledger that this transaction was included in. Only present in responses toaccount_tx
rippled calls.- Specified by:
ledgerIndex
in interfaceTransaction
- Returns:
- An optionally-present
LedgerIndex
.
-
flags
public Flags.PaymentChannelClaimFlags flags()
Bit-map of booleanFlags.PaymentChannelClaimFlags
to set for this transaction.- Specified by:
flags
in interfacePaymentChannelClaim
- Returns:
- The
Flags.PaymentChannelClaimFlags
for this transaction.
-
channel
public Hash256 channel()
The unique ID of the channel, as aHash256
.- Specified by:
channel
in interfacePaymentChannelClaim
- Returns:
- A
Hash256
representing the channel ID.
-
balance
public Optional<XrpCurrencyAmount> balance()
Total amount of XRP, in drops, delivered by this channel after processing this claim. Required to deliver XRP. Must be more than the total amount delivered by the channel so far, but not greater than theamount()
of the signed claim. Must be provided except when closing the channel.- Specified by:
balance
in interfacePaymentChannelClaim
- Returns:
- An
Optional
of typeXrpCurrencyAmount
representing the payment channel balance.
-
amount
public Optional<XrpCurrencyAmount> amount()
The amount of XRP, in drops, authorized by thesignature()
. This must match the amount in the signed message. This is the cumulative amount of XRP that can be dispensed by the channel, including XRP previously redeemed.- Specified by:
amount
in interfacePaymentChannelClaim
- Returns:
- An
Optional
of typeXrpCurrencyAmount
representing the payment channel amount.
-
signature
public Optional<String> signature()
The signature of this claim, in hexadecimal form. The signed message contains the channel ID and the amount of the claim. Required unless the sender of the transaction is the source address of the channel.- Specified by:
signature
in interfacePaymentChannelClaim
- Returns:
- An
Optional
of typeString
containing the payment channel signature.
-
publicKey
public Optional<String> publicKey()
The public key used for thesignature()
, as hexadecimal. This must match the PublicKey stored in the ledger for the channel. Required unless the sender of the transaction is the source address of the channel and thesignature()
field is omitted. (The transaction includes the public key so that rippled can check the validity of the signature before trying to apply the transaction to the ledger.)- Specified by:
publicKey
in interfacePaymentChannelClaim
- Returns:
- An
Optional
of typeString
containing the public key used to sign this payment channel.
-
withAccount
public final ImmutablePaymentChannelClaim withAccount(Address value)
Copy the current immutable object by setting a value for theaccount
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for account- Returns:
- A modified copy of the
this
object
-
withFee
public final ImmutablePaymentChannelClaim withFee(XrpCurrencyAmount value)
Copy the current immutable object by setting a value for thefee
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for fee- Returns:
- A modified copy of the
this
object
-
withSequence
public final ImmutablePaymentChannelClaim withSequence(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a value for thesequence
attribute. An equals check used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for sequence- Returns:
- A modified copy of the
this
object
-
withAccountTransactionId
public final ImmutablePaymentChannelClaim withAccountTransactionId(Hash256 value)
Copy the current immutable object by setting a present value for the optionalaccountTransactionId
attribute.- Parameters:
value
- The value for accountTransactionId- Returns:
- A modified copy of
this
object
-
withAccountTransactionId
public final ImmutablePaymentChannelClaim withAccountTransactionId(Optional<? extends Hash256> optional)
Copy the current immutable object by setting an optional value for theaccountTransactionId
attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for accountTransactionId- Returns:
- A modified copy of
this
object
-
withLastLedgerSequence
public final ImmutablePaymentChannelClaim withLastLedgerSequence(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionallastLedgerSequence
attribute.- Parameters:
value
- The value for lastLedgerSequence- Returns:
- A modified copy of
this
object
-
withLastLedgerSequence
public final ImmutablePaymentChannelClaim withLastLedgerSequence(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thelastLedgerSequence
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for lastLedgerSequence- Returns:
- A modified copy of
this
object
-
withMemos
public final ImmutablePaymentChannelClaim withMemos(MemoWrapper... elements)
Copy the current immutable object with elements that replace the content ofmemos
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withMemos
public final ImmutablePaymentChannelClaim withMemos(Iterable<? extends MemoWrapper> elements)
Copy the current immutable object with elements that replace the content ofmemos
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of memos elements to set- Returns:
- A modified copy of
this
object
-
withSigners
public final ImmutablePaymentChannelClaim withSigners(SignerWrapper... elements)
Copy the current immutable object with elements that replace the content ofsigners
.- Parameters:
elements
- The elements to set- Returns:
- A modified copy of
this
object
-
withSigners
public final ImmutablePaymentChannelClaim withSigners(Iterable<? extends SignerWrapper> elements)
Copy the current immutable object with elements that replace the content ofsigners
. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
elements
- An iterable of signers elements to set- Returns:
- A modified copy of
this
object
-
withSourceTag
public final ImmutablePaymentChannelClaim withSourceTag(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionalsourceTag
attribute.- Parameters:
value
- The value for sourceTag- Returns:
- A modified copy of
this
object
-
withSourceTag
public final ImmutablePaymentChannelClaim withSourceTag(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thesourceTag
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for sourceTag- Returns:
- A modified copy of
this
object
-
withSigningPublicKey
public final ImmutablePaymentChannelClaim withSigningPublicKey(String value)
Copy the current immutable object by setting a present value for the optionalsigningPublicKey
attribute.- Parameters:
value
- The value for signingPublicKey- Returns:
- A modified copy of
this
object
-
withSigningPublicKey
public final ImmutablePaymentChannelClaim withSigningPublicKey(Optional<String> optional)
Copy the current immutable object by setting an optional value for thesigningPublicKey
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for signingPublicKey- Returns:
- A modified copy of
this
object
-
withTransactionSignature
public final ImmutablePaymentChannelClaim withTransactionSignature(String value)
Copy the current immutable object by setting a present value for the optionaltransactionSignature
attribute.- Parameters:
value
- The value for transactionSignature- Returns:
- A modified copy of
this
object
-
withTransactionSignature
public final ImmutablePaymentChannelClaim withTransactionSignature(Optional<String> optional)
Copy the current immutable object by setting an optional value for thetransactionSignature
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for transactionSignature- Returns:
- A modified copy of
this
object
-
withCloseDate
@Deprecated public final ImmutablePaymentChannelClaim withCloseDate(com.google.common.primitives.UnsignedLong value)
Deprecated.Copy the current immutable object by setting a present value for the optionalcloseDate
attribute.- Parameters:
value
- The value for closeDate- Returns:
- A modified copy of
this
object
-
withCloseDate
@Deprecated public final ImmutablePaymentChannelClaim withCloseDate(Optional<? extends com.google.common.primitives.UnsignedLong> optional)
Deprecated.Copy the current immutable object by setting an optional value for thecloseDate
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for closeDate- Returns:
- A modified copy of
this
object
-
withHash
@Deprecated public final ImmutablePaymentChannelClaim withHash(Hash256 value)
Deprecated.Copy the current immutable object by setting a present value for the optionalhash
attribute.- Parameters:
value
- The value for hash- Returns:
- A modified copy of
this
object
-
withHash
@Deprecated public final ImmutablePaymentChannelClaim withHash(Optional<? extends Hash256> optional)
Deprecated.Copy the current immutable object by setting an optional value for thehash
attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for hash- Returns:
- A modified copy of
this
object
-
withLedgerIndex
@Deprecated public final ImmutablePaymentChannelClaim withLedgerIndex(LedgerIndex value)
Deprecated.Copy the current immutable object by setting a present value for the optionalledgerIndex
attribute.- Parameters:
value
- The value for ledgerIndex- Returns:
- A modified copy of
this
object
-
withLedgerIndex
@Deprecated public final ImmutablePaymentChannelClaim withLedgerIndex(Optional<? extends LedgerIndex> optional)
Deprecated.Copy the current immutable object by setting an optional value for theledgerIndex
attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for ledgerIndex- Returns:
- A modified copy of
this
object
-
withFlags
public final ImmutablePaymentChannelClaim withFlags(Flags.PaymentChannelClaimFlags value)
Copy the current immutable object by setting a value for theflags
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for flags- Returns:
- A modified copy of the
this
object
-
withChannel
public final ImmutablePaymentChannelClaim withChannel(Hash256 value)
Copy the current immutable object by setting a value for thechannel
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for channel- Returns:
- A modified copy of the
this
object
-
withBalance
public final ImmutablePaymentChannelClaim withBalance(XrpCurrencyAmount value)
Copy the current immutable object by setting a present value for the optionalbalance
attribute.- Parameters:
value
- The value for balance- Returns:
- A modified copy of
this
object
-
withBalance
public final ImmutablePaymentChannelClaim withBalance(Optional<? extends XrpCurrencyAmount> optional)
Copy the current immutable object by setting an optional value for thebalance
attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for balance- Returns:
- A modified copy of
this
object
-
withAmount
public final ImmutablePaymentChannelClaim withAmount(XrpCurrencyAmount value)
Copy the current immutable object by setting a present value for the optionalamount
attribute.- Parameters:
value
- The value for amount- Returns:
- A modified copy of
this
object
-
withAmount
public final ImmutablePaymentChannelClaim withAmount(Optional<? extends XrpCurrencyAmount> optional)
Copy the current immutable object by setting an optional value for theamount
attribute. A shallow reference equality check is used on unboxed optional value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for amount- Returns:
- A modified copy of
this
object
-
withSignature
public final ImmutablePaymentChannelClaim withSignature(String value)
Copy the current immutable object by setting a present value for the optionalsignature
attribute.- Parameters:
value
- The value for signature- Returns:
- A modified copy of
this
object
-
withSignature
public final ImmutablePaymentChannelClaim withSignature(Optional<String> optional)
Copy the current immutable object by setting an optional value for thesignature
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for signature- Returns:
- A modified copy of
this
object
-
withPublicKey
public final ImmutablePaymentChannelClaim withPublicKey(String value)
Copy the current immutable object by setting a present value for the optionalpublicKey
attribute.- Parameters:
value
- The value for publicKey- Returns:
- A modified copy of
this
object
-
withPublicKey
public final ImmutablePaymentChannelClaim withPublicKey(Optional<String> optional)
Copy the current immutable object by setting an optional value for thepublicKey
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for publicKey- Returns:
- A modified copy of
this
object
-
equals
public boolean equals(@Nullable Object another)
This instance is equal to all instances ofImmutablePaymentChannelClaim
that have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:account
,fee
,sequence
,accountTransactionId
,lastLedgerSequence
,memos
,signers
,sourceTag
,signingPublicKey
,transactionSignature
,closeDate
,hash
,ledgerIndex
,flags
,channel
,balance
,amount
,signature
,publicKey
.
-
toString
public String toString()
Prints the immutable valuePaymentChannelClaim
with attribute values.
-
copyOf
public static ImmutablePaymentChannelClaim copyOf(PaymentChannelClaim instance)
Creates an immutable copy of aPaymentChannelClaim
value. Uses accessors to get values to initialize the new immutable instance. If an instance is already immutable, it is returned as is.- Parameters:
instance
- The instance to copy- Returns:
- A copied immutable PaymentChannelClaim instance
-
builder
public static ImmutablePaymentChannelClaim.Builder builder()
Creates a builder forImmutablePaymentChannelClaim
.ImmutablePaymentChannelClaim.builder() .account(org.xrpl.xrpl4j.model.transactions.Address) // required
account
.fee(org.xrpl.xrpl4j.model.transactions.XrpCurrencyAmount) // requiredfee
.sequence(com.google.common.primitives.UnsignedInteger) // requiredsequence
.accountTransactionId(Hash256) // optionalaccountTransactionId
.lastLedgerSequence(com.google.common.primitives.UnsignedInteger) // optionallastLedgerSequence
.addMemos|addAllMemos(org.xrpl.xrpl4j.model.transactions.MemoWrapper) //memos
elements .addSigners|addAllSigners(org.xrpl.xrpl4j.model.transactions.SignerWrapper) //signers
elements .sourceTag(com.google.common.primitives.UnsignedInteger) // optionalsourceTag
.signingPublicKey(String) // optionalsigningPublicKey
.transactionSignature(String) // optionaltransactionSignature
.closeDate(com.google.common.primitives.UnsignedLong) // optionalcloseDate
.hash(Hash256) // optionalhash
.ledgerIndex(org.xrpl.xrpl4j.model.client.common.LedgerIndex) // optionalledgerIndex
.flags(org.xrpl.xrpl4j.model.flags.Flags.PaymentChannelClaimFlags) // optionalflags
.channel(org.xrpl.xrpl4j.model.transactions.Hash256) // requiredchannel
.balance(XrpCurrencyAmount) // optionalbalance
.amount(XrpCurrencyAmount) // optionalamount
.signature(String) // optionalsignature
.publicKey(String) // optionalpublicKey
.build();- Returns:
- A new ImmutablePaymentChannelClaim builder
-
-