Package org.xrpl.xrpl4j.model.client.mpt
Class ImmutableMptHoldersMpToken.Builder
java.lang.Object
org.xrpl.xrpl4j.model.client.mpt.ImmutableMptHoldersMpToken.Builder
- Enclosing class:
ImmutableMptHoldersMpToken
Builds instances of type
ImmutableMptHoldersMpToken.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
-
Method Summary
Modifier and TypeMethodDescriptionInitializes the value for theaccountattribute.build()Builds a newImmutableMptHoldersMpToken.flags(MpTokenFlags flags) Initializes the value for theflagsattribute.from(MptHoldersMpToken instance) Fill a builder with attribute values from the providedMptHoldersMpTokeninstance.lockedAmount(Optional<? extends MpTokenNumericAmount> lockedAmount) Initializes the optional valuelockedAmountto lockedAmount.lockedAmount(MpTokenNumericAmount lockedAmount) Initializes the optional valuelockedAmountto lockedAmount.mptAmount(MpTokenNumericAmount mptAmount) Initializes the value for themptAmountattribute.mpTokenIndex(Hash256 mpTokenIndex) Initializes the value for thempTokenIndexattribute.
-
Method Details
-
from
@CanIgnoreReturnValue public final ImmutableMptHoldersMpToken.Builder from(MptHoldersMpToken instance) Fill a builder with attribute values from the providedMptHoldersMpTokeninstance. Regular attribute values will be replaced with those from the given instance. Absent optional values will not replace present values.- Parameters:
instance- The instance from which to copy values- Returns:
thisbuilder for use in a chained invocation
-
account
Initializes the value for theaccountattribute.- Parameters:
account- The value for account- Returns:
thisbuilder for use in a chained invocation
-
flags
Initializes the value for theflagsattribute.- Parameters:
flags- The value for flags- Returns:
thisbuilder for use in a chained invocation
-
mptAmount
@CanIgnoreReturnValue public final ImmutableMptHoldersMpToken.Builder mptAmount(MpTokenNumericAmount mptAmount) Initializes the value for themptAmountattribute.- Parameters:
mptAmount- The value for mptAmount- Returns:
thisbuilder for use in a chained invocation
-
lockedAmount
@CanIgnoreReturnValue public final ImmutableMptHoldersMpToken.Builder lockedAmount(MpTokenNumericAmount lockedAmount) Initializes the optional valuelockedAmountto lockedAmount.- Parameters:
lockedAmount- The value for lockedAmount- Returns:
thisbuilder for chained invocation
-
lockedAmount
@CanIgnoreReturnValue public final ImmutableMptHoldersMpToken.Builder lockedAmount(Optional<? extends MpTokenNumericAmount> lockedAmount) Initializes the optional valuelockedAmountto lockedAmount.- Parameters:
lockedAmount- The value for lockedAmount- Returns:
thisbuilder for use in a chained invocation
-
mpTokenIndex
@CanIgnoreReturnValue public final ImmutableMptHoldersMpToken.Builder mpTokenIndex(Hash256 mpTokenIndex) Initializes the value for thempTokenIndexattribute.- Parameters:
mpTokenIndex- The value for mpTokenIndex- Returns:
thisbuilder for use in a chained invocation
-
build
Builds a newImmutableMptHoldersMpToken.- Returns:
- An immutable instance of MptHoldersMpToken
- Throws:
IllegalStateException- if any required attributes are missing
-