Class ImmutableAccountChannelsRequestParams
- java.lang.Object
-
- org.xrpl.xrpl4j.model.client.accounts.ImmutableAccountChannelsRequestParams
-
- All Implemented Interfaces:
AccountChannelsRequestParams
,XrplRequestParams
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableAccountChannelsRequestParams extends Object implements AccountChannelsRequestParams
Immutable implementation ofAccountChannelsRequestParams
.Use the builder to create immutable instances:
ImmutableAccountChannelsRequestParams.builder()
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ImmutableAccountChannelsRequestParams.Builder
Builds instances of typeImmutableAccountChannelsRequestParams
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Address
account()
The uniqueAddress
for the account.static ImmutableAccountChannelsRequestParams.Builder
builder()
Creates a builder forImmutableAccountChannelsRequestParams
.static ImmutableAccountChannelsRequestParams
copyOf(AccountChannelsRequestParams instance)
Creates an immutable copy of aAccountChannelsRequestParams
value.Optional<Address>
destinationAccount()
The uniqueAddress
for the destination account.boolean
equals(Object another)
This instance is equal to all instances ofImmutableAccountChannelsRequestParams
that have equal attribute values.int
hashCode()
Computes a hash code from attributes:account
,destinationAccount
,ledgerSpecifier
,limit
,marker
.Optional<Hash256>
ledgerHash()
Deprecated.Ledger hash should be specified inledgerSpecifier()
.LedgerIndex
ledgerIndex()
Deprecated.Ledger index and any shortcut values should be specified inledgerSpecifier()
.LedgerSpecifier
ledgerSpecifier()
Specifies the ledger version to request.Optional<com.google.common.primitives.UnsignedInteger>
limit()
Limit the number of transactions to retrieve.Optional<Marker>
marker()
Value from a previous paginated response.String
toString()
Prints the immutable valueAccountChannelsRequestParams
with attribute values.ImmutableAccountChannelsRequestParams
withAccount(Address value)
Copy the current immutable object by setting a value for theaccount
attribute.ImmutableAccountChannelsRequestParams
withDestinationAccount(Optional<? extends Address> optional)
Copy the current immutable object by setting an optional value for thedestinationAccount
attribute.ImmutableAccountChannelsRequestParams
withDestinationAccount(Address value)
Copy the current immutable object by setting a present value for the optionaldestinationAccount
attribute.ImmutableAccountChannelsRequestParams
withLedgerHash(Optional<? extends Hash256> optional)
Deprecated.ImmutableAccountChannelsRequestParams
withLedgerHash(Hash256 value)
Deprecated.ImmutableAccountChannelsRequestParams
withLedgerIndex(LedgerIndex value)
Deprecated.ImmutableAccountChannelsRequestParams
withLedgerSpecifier(LedgerSpecifier value)
Copy the current immutable object by setting a value for theledgerSpecifier
attribute.ImmutableAccountChannelsRequestParams
withLimit(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionallimit
attribute.ImmutableAccountChannelsRequestParams
withLimit(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thelimit
attribute.ImmutableAccountChannelsRequestParams
withMarker(Optional<? extends Marker> optional)
Copy the current immutable object by setting an optional value for themarker
attribute.ImmutableAccountChannelsRequestParams
withMarker(Marker value)
Copy the current immutable object by setting a present value for the optionalmarker
attribute.
-
-
-
Method Detail
-
account
public Address account()
The uniqueAddress
for the account. The request returns channels where this account is the channel's owner/source.- Specified by:
account
in interfaceAccountChannelsRequestParams
- Returns:
- The
Address
for the account.
-
destinationAccount
public Optional<Address> destinationAccount()
The uniqueAddress
for the destination account. If provided, the response results are filtered by channels whose destination is this account.- Specified by:
destinationAccount
in interfaceAccountChannelsRequestParams
- Returns:
- The optionally present
Address
of the destination account.
-
ledgerHash
@Deprecated public Optional<Hash256> ledgerHash()
Deprecated.Ledger hash should be specified inledgerSpecifier()
.A 20-byte hex string for the ledger version to use.- Specified by:
ledgerHash
in interfaceAccountChannelsRequestParams
- Returns:
- An optionally-present
Hash256
.
-
ledgerIndex
@Deprecated @Nullable public LedgerIndex ledgerIndex()
Deprecated.Ledger index and any shortcut values should be specified inledgerSpecifier()
.The ledger index of the ledger to use, or a shortcut string to choose a ledger automatically.- Specified by:
ledgerIndex
in interfaceAccountChannelsRequestParams
- Returns:
- A
LedgerIndex
. Defaults toLedgerIndex.CURRENT
.
-
ledgerSpecifier
public LedgerSpecifier ledgerSpecifier()
Specifies the ledger version to request. A ledger version can be specified by ledger hash, numerical ledger index, or a shortcut value.- Specified by:
ledgerSpecifier
in interfaceAccountChannelsRequestParams
- Returns:
- A
LedgerSpecifier
specifying the ledger version to request.
-
limit
public Optional<com.google.common.primitives.UnsignedInteger> limit()
Limit the number of transactions to retrieve. Cannot be less than 10 or more than 400. The default is 200.- Specified by:
limit
in interfaceAccountChannelsRequestParams
- Returns:
- An optionally-present
UnsignedInteger
.
-
marker
public Optional<Marker> marker()
Value from a previous paginated response. Resume retrieving data where that response left off.- Specified by:
marker
in interfaceAccountChannelsRequestParams
- Returns:
- An optionally-present
String
.
-
withAccount
public final ImmutableAccountChannelsRequestParams 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
-
withDestinationAccount
public final ImmutableAccountChannelsRequestParams withDestinationAccount(Address value)
Copy the current immutable object by setting a present value for the optionaldestinationAccount
attribute.- Parameters:
value
- The value for destinationAccount- Returns:
- A modified copy of
this
object
-
withDestinationAccount
public final ImmutableAccountChannelsRequestParams withDestinationAccount(Optional<? extends Address> optional)
Copy the current immutable object by setting an optional value for thedestinationAccount
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 destinationAccount- Returns:
- A modified copy of
this
object
-
withLedgerHash
@Deprecated public final ImmutableAccountChannelsRequestParams withLedgerHash(Hash256 value)
Deprecated.Copy the current immutable object by setting a present value for the optionalledgerHash
attribute.- Parameters:
value
- The value for ledgerHash- Returns:
- A modified copy of
this
object
-
withLedgerHash
@Deprecated public final ImmutableAccountChannelsRequestParams withLedgerHash(Optional<? extends Hash256> optional)
Deprecated.Copy the current immutable object by setting an optional value for theledgerHash
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 ledgerHash- Returns:
- A modified copy of
this
object
-
withLedgerIndex
@Deprecated public final ImmutableAccountChannelsRequestParams withLedgerIndex(@Nullable LedgerIndex value)
Deprecated.Copy the current immutable object by setting a value for theledgerIndex
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for ledgerIndex (can benull
)- Returns:
- A modified copy of the
this
object
-
withLedgerSpecifier
public final ImmutableAccountChannelsRequestParams withLedgerSpecifier(LedgerSpecifier value)
Copy the current immutable object by setting a value for theledgerSpecifier
attribute. A shallow reference equality check is used to prevent copying of the same value by returningthis
.- Parameters:
value
- A new value for ledgerSpecifier- Returns:
- A modified copy of the
this
object
-
withLimit
public final ImmutableAccountChannelsRequestParams withLimit(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionallimit
attribute.- Parameters:
value
- The value for limit- Returns:
- A modified copy of
this
object
-
withLimit
public final ImmutableAccountChannelsRequestParams withLimit(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thelimit
attribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis
.- Parameters:
optional
- A value for limit- Returns:
- A modified copy of
this
object
-
withMarker
public final ImmutableAccountChannelsRequestParams withMarker(Marker value)
Copy the current immutable object by setting a present value for the optionalmarker
attribute.- Parameters:
value
- The value for marker- Returns:
- A modified copy of
this
object
-
withMarker
public final ImmutableAccountChannelsRequestParams withMarker(Optional<? extends Marker> optional)
Copy the current immutable object by setting an optional value for themarker
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 marker- Returns:
- A modified copy of
this
object
-
equals
public boolean equals(@Nullable Object another)
This instance is equal to all instances ofImmutableAccountChannelsRequestParams
that have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:account
,destinationAccount
,ledgerSpecifier
,limit
,marker
.
-
toString
public String toString()
Prints the immutable valueAccountChannelsRequestParams
with attribute values.
-
copyOf
public static ImmutableAccountChannelsRequestParams copyOf(AccountChannelsRequestParams instance)
Creates an immutable copy of aAccountChannelsRequestParams
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 AccountChannelsRequestParams instance
-
builder
public static ImmutableAccountChannelsRequestParams.Builder builder()
Creates a builder forImmutableAccountChannelsRequestParams
.ImmutableAccountChannelsRequestParams.builder() .account(org.xrpl.xrpl4j.model.transactions.Address) // required
account
.destinationAccount(org.xrpl.xrpl4j.model.transactions.Address) // optionaldestinationAccount
.ledgerHash(org.xrpl.xrpl4j.model.transactions.Hash256) // optionalledgerHash
.ledgerIndex(org.xrpl.xrpl4j.model.client.common.LedgerIndex | null) // nullableledgerIndex
.ledgerSpecifier(org.xrpl.xrpl4j.model.client.common.LedgerSpecifier) // optionalledgerSpecifier
.limit(com.google.common.primitives.UnsignedInteger) // optionallimit
.marker(org.xrpl.xrpl4j.model.transactions.Marker) // optionalmarker
.build();- Returns:
- A new ImmutableAccountChannelsRequestParams builder
-
-