Package org.xrpl.xrpl4j.model.ledger
Class ImmutableAuctionSlot
java.lang.Object
org.xrpl.xrpl4j.model.ledger.ImmutableAuctionSlot
- All Implemented Interfaces:
AuctionSlot
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class ImmutableAuctionSlot
extends Object
implements AuctionSlot
Immutable implementation of
AuctionSlot.
Use the builder to create immutable instances:
ImmutableAuctionSlot.builder().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutableAuctionSlot. -
Method Summary
Modifier and TypeMethodDescriptionaccount()The current owner of this auction slot.com.google.common.collect.ImmutableList<AuthAccountWrapper> A list of at most 4 additional accounts that are authorized to trade at the discounted fee for this AMM instance.Extracts all the addresses found in theAuthAccounts found inauthAccounts().static ImmutableAuctionSlot.Builderbuilder()Creates a builder forImmutableAuctionSlot.static ImmutableAuctionSlotcopyOf(AuctionSlot instance) Creates an immutable copy of aAuctionSlotvalue.The trading fee to be charged to the auction owner.booleanThis instance is equal to all instances ofImmutableAuctionSlotthat have equal attribute values.com.google.common.primitives.UnsignedIntegerThe time when this slot expires, in seconds since the Ripple Epoch.inthashCode()Computes a hash code from attributes:account,authAccounts,authAccountsAddresses,discountedFee,price,expiration.price()The amount the auction owner paid to win this slot, in LP Tokens.toString()Prints the immutable valueAuctionSlotwith attribute values.final ImmutableAuctionSlotwithAccount(Address value) Copy the current immutable object by setting a value for theaccountattribute.final ImmutableAuctionSlotwithAuthAccounts(Iterable<? extends AuthAccountWrapper> elements) Copy the current immutable object with elements that replace the content ofauthAccounts.final ImmutableAuctionSlotwithAuthAccounts(AuthAccountWrapper... elements) Copy the current immutable object with elements that replace the content ofauthAccounts.final ImmutableAuctionSlotwithDiscountedFee(TradingFee value) Copy the current immutable object by setting a value for thediscountedFeeattribute.final ImmutableAuctionSlotwithExpiration(com.google.common.primitives.UnsignedInteger value) Copy the current immutable object by setting a value for theexpirationattribute.final ImmutableAuctionSlotwithPrice(IssuedCurrencyAmount value) Copy the current immutable object by setting a value for thepriceattribute.
-
Method Details
-
account
The current owner of this auction slot.- Specified by:
accountin interfaceAuctionSlot- Returns:
- An
Address.
-
authAccounts
A list of at most 4 additional accounts that are authorized to trade at the discounted fee for this AMM instance.- Specified by:
authAccountsin interfaceAuctionSlot- Returns:
- A
ListofAuthAccountWrappers.
-
authAccountsAddresses
Extracts all the addresses found in theAuthAccounts found inauthAccounts().- Specified by:
authAccountsAddressesin interfaceAuctionSlot- Returns:
- A
ListofAddress.
-
discountedFee
The trading fee to be charged to the auction owner. By default this is 0, meaning that the auction owner can trade at no fee instead of the standard fee for this AMM.- Specified by:
discountedFeein interfaceAuctionSlot- Returns:
- A
TradingFee.
-
price
The amount the auction owner paid to win this slot, in LP Tokens.- Specified by:
pricein interfaceAuctionSlot- Returns:
- An
IssuedCurrencyAmount.
-
expiration
public com.google.common.primitives.UnsignedInteger expiration()The time when this slot expires, in seconds since the Ripple Epoch.- Specified by:
expirationin interfaceAuctionSlot- Returns:
- An
UnsignedInteger
-
withAccount
Copy the current immutable object by setting a value for theaccountattribute. 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
thisobject
-
withAuthAccounts
Copy the current immutable object with elements that replace the content ofauthAccounts.- Parameters:
elements- The elements to set- Returns:
- A modified copy of
thisobject
-
withAuthAccounts
Copy the current immutable object with elements that replace the content ofauthAccounts. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
elements- An iterable of authAccounts elements to set- Returns:
- A modified copy of
thisobject
-
withDiscountedFee
Copy the current immutable object by setting a value for thediscountedFeeattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for discountedFee- Returns:
- A modified copy of the
thisobject
-
withPrice
Copy the current immutable object by setting a value for thepriceattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for price- Returns:
- A modified copy of the
thisobject
-
withExpiration
public final ImmutableAuctionSlot withExpiration(com.google.common.primitives.UnsignedInteger value) Copy the current immutable object by setting a value for theexpirationattribute. An equals check used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for expiration- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofImmutableAuctionSlotthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:account,authAccounts,authAccountsAddresses,discountedFee,price,expiration. -
toString
Prints the immutable valueAuctionSlotwith attribute values. -
copyOf
Creates an immutable copy of aAuctionSlotvalue. 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 AuctionSlot instance
-
builder
Creates a builder forImmutableAuctionSlot.ImmutableAuctionSlot.builder() .account(org.xrpl.xrpl4j.model.transactions.Address) // requiredaccount.addAuthAccounts|addAllAuthAccounts(org.xrpl.xrpl4j.model.ledger.AuthAccountWrapper) //authAccountselements .discountedFee(org.xrpl.xrpl4j.model.transactions.TradingFee) // requireddiscountedFee.price(org.xrpl.xrpl4j.model.transactions.IssuedCurrencyAmount) // requiredprice.expiration(com.google.common.primitives.UnsignedInteger) // requiredexpiration.build();- Returns:
- A new ImmutableAuctionSlot builder
-