Class ImmutableMemo
java.lang.Object
org.xrpl.xrpl4j.model.transactions.Memo
org.xrpl.xrpl4j.model.transactions.ImmutableMemo
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class ImmutableMemo
extends Memo
Immutable implementation of
Memo.
Use the builder to create immutable instances:
ImmutableMemo.builder().
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic ImmutableMemo.Builderbuilder()Creates a builder forImmutableMemo.static ImmutableMemoCreates an immutable copy of aMemovalue.booleanThis instance is equal to all instances ofImmutableMemothat have equal attribute values.inthashCode()Computes a hash code from attributes:memoData,memoFormat,memoType.memoData()Arbitrary hex value, conventionally containing the content of the memo.Hex value representing characters allowed in URLs.memoType()Hex value representing characters allowed in URLs.toString()Prints the immutable valueMemowith attribute values.final ImmutableMemowithMemoData(String value) Copy the current immutable object by setting a present value for the optionalmemoDataattribute.final ImmutableMemowithMemoData(Optional<String> optional) Copy the current immutable object by setting an optional value for thememoDataattribute.final ImmutableMemowithMemoFormat(String value) Copy the current immutable object by setting a present value for the optionalmemoFormatattribute.final ImmutableMemowithMemoFormat(Optional<String> optional) Copy the current immutable object by setting an optional value for thememoFormatattribute.final ImmutableMemowithMemoType(String value) Copy the current immutable object by setting a present value for the optionalmemoTypeattribute.final ImmutableMemowithMemoType(Optional<String> optional) Copy the current immutable object by setting an optional value for thememoTypeattribute.Methods inherited from class org.xrpl.xrpl4j.model.transactions.Memo
withPlaintext
-
Method Details
-
memoData
Arbitrary hex value, conventionally containing the content of the memo. -
memoFormat
Hex value representing characters allowed in URLs. Conventionally containing information on how the memo is encoded.- Specified by:
memoFormatin classMemo- Returns:
- An
Optionalof typeStringcontaining the memo format.
-
memoType
Hex value representing characters allowed in URLs. Conventionally, a unique relation that defines the format of this memo. -
withMemoData
Copy the current immutable object by setting a present value for the optionalmemoDataattribute.- Parameters:
value- The value for memoData- Returns:
- A modified copy of
thisobject
-
withMemoData
Copy the current immutable object by setting an optional value for thememoDataattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for memoData- Returns:
- A modified copy of
thisobject
-
withMemoFormat
Copy the current immutable object by setting a present value for the optionalmemoFormatattribute.- Parameters:
value- The value for memoFormat- Returns:
- A modified copy of
thisobject
-
withMemoFormat
Copy the current immutable object by setting an optional value for thememoFormatattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for memoFormat- Returns:
- A modified copy of
thisobject
-
withMemoType
Copy the current immutable object by setting a present value for the optionalmemoTypeattribute.- Parameters:
value- The value for memoType- Returns:
- A modified copy of
thisobject
-
withMemoType
Copy the current immutable object by setting an optional value for thememoTypeattribute. An equality check is used on inner nullable value to prevent copying of the same value by returningthis.- Parameters:
optional- A value for memoType- Returns:
- A modified copy of
thisobject
-
equals
This instance is equal to all instances ofImmutableMemothat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:memoData,memoFormat,memoType. -
toString
Prints the immutable valueMemowith attribute values. -
copyOf
Creates an immutable copy of aMemovalue. 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 Memo instance
-
builder
Creates a builder forImmutableMemo.ImmutableMemo.builder() .memoData(String) // optionalmemoData.memoFormat(String) // optionalmemoFormat.memoType(String) // optionalmemoType.build();- Returns:
- A new ImmutableMemo builder
-