Class ImmutableAccountOffersRequestParams
- java.lang.Object
-
- org.xrpl.xrpl4j.model.client.accounts.ImmutableAccountOffersRequestParams
-
- All Implemented Interfaces:
AccountOffersRequestParams
,XrplRequestParams
@ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable @CheckReturnValue public final class ImmutableAccountOffersRequestParams extends Object implements AccountOffersRequestParams
Immutable implementation ofAccountOffersRequestParams
.Use the builder to create immutable instances:
ImmutableAccountOffersRequestParams.builder()
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ImmutableAccountOffersRequestParams.Builder
Builds instances of typeImmutableAccountOffersRequestParams
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Address
account()
A unique identifier for the account, most commonly the account'sAddress
.static ImmutableAccountOffersRequestParams.Builder
builder()
Creates a builder forImmutableAccountOffersRequestParams
.static ImmutableAccountOffersRequestParams
copyOf(AccountOffersRequestParams instance)
Creates an immutable copy of aAccountOffersRequestParams
value.boolean
equals(Object another)
This instance is equal to all instances ofImmutableAccountOffersRequestParams
that have equal attribute values.int
hashCode()
Computes a hash code from attributes:account
,ledgerSpecifier
,strict
,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.boolean
strict()
String
toString()
Prints the immutable valueAccountOffersRequestParams
with attribute values.ImmutableAccountOffersRequestParams
withAccount(Address value)
Copy the current immutable object by setting a value for theaccount
attribute.ImmutableAccountOffersRequestParams
withLedgerHash(Optional<? extends Hash256> optional)
Deprecated.ImmutableAccountOffersRequestParams
withLedgerHash(Hash256 value)
Deprecated.ImmutableAccountOffersRequestParams
withLedgerIndex(LedgerIndex value)
Deprecated.ImmutableAccountOffersRequestParams
withLedgerSpecifier(LedgerSpecifier value)
Copy the current immutable object by setting a value for theledgerSpecifier
attribute.ImmutableAccountOffersRequestParams
withLimit(com.google.common.primitives.UnsignedInteger value)
Copy the current immutable object by setting a present value for the optionallimit
attribute.ImmutableAccountOffersRequestParams
withLimit(Optional<? extends com.google.common.primitives.UnsignedInteger> optional)
Copy the current immutable object by setting an optional value for thelimit
attribute.ImmutableAccountOffersRequestParams
withMarker(Optional<? extends Marker> optional)
Copy the current immutable object by setting an optional value for themarker
attribute.ImmutableAccountOffersRequestParams
withMarker(Marker value)
Copy the current immutable object by setting a present value for the optionalmarker
attribute.
-
-
-
Method Detail
-
account
public Address account()
A unique identifier for the account, most commonly the account'sAddress
.- Specified by:
account
in interfaceAccountOffersRequestParams
- Returns:
- The
Address
for the 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 interfaceAccountOffersRequestParams
- 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 interfaceAccountOffersRequestParams
- 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 interfaceAccountOffersRequestParams
- Returns:
- A
LedgerSpecifier
specifying the ledger version to request.
-
strict
public boolean strict()
A boolean indicating if theaccount()
field only accepts a public key or XRP LedgerAddress
. Always true, asaccount()
is always anAddress
.- Specified by:
strict
in interfaceAccountOffersRequestParams
- Returns:
true
if the account field only accepts a public key or XRP Ledger address, otherwisefalse
. Defaults totrue
.
-
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 server is not required to honor this value and the default varies.- Specified by:
limit
in interfaceAccountOffersRequestParams
- 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 interfaceAccountOffersRequestParams
- Returns:
- An optionally-present
String
.
-
withAccount
public final ImmutableAccountOffersRequestParams 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
-
withLedgerHash
@Deprecated public final ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ImmutableAccountOffersRequestParams 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 ofImmutableAccountOffersRequestParams
that have equal attribute values.
-
hashCode
public int hashCode()
Computes a hash code from attributes:account
,ledgerSpecifier
,strict
,limit
,marker
.
-
toString
public String toString()
Prints the immutable valueAccountOffersRequestParams
with attribute values.
-
copyOf
public static ImmutableAccountOffersRequestParams copyOf(AccountOffersRequestParams instance)
Creates an immutable copy of aAccountOffersRequestParams
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 AccountOffersRequestParams instance
-
builder
public static ImmutableAccountOffersRequestParams.Builder builder()
Creates a builder forImmutableAccountOffersRequestParams
.ImmutableAccountOffersRequestParams.builder() .account(org.xrpl.xrpl4j.model.transactions.Address) // required
account
.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 ImmutableAccountOffersRequestParams builder
-
-