Class ImmutablePermissionWrapper
java.lang.Object
org.xrpl.xrpl4j.model.transactions.ImmutablePermissionWrapper
- All Implemented Interfaces:
PermissionWrapper
@ParametersAreNonnullByDefault
@Generated("org.immutables.processor.ProxyProcessor")
@Immutable
@CheckReturnValue
public final class ImmutablePermissionWrapper
extends Object
implements PermissionWrapper
Immutable implementation of
PermissionWrapper.
Use the builder to create immutable instances:
ImmutablePermissionWrapper.builder().
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classBuilds instances of typeImmutablePermissionWrapper. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Creates a builder forImmutablePermissionWrapper.static ImmutablePermissionWrappercopyOf(PermissionWrapper instance) Creates an immutable copy of aPermissionWrappervalue.booleanThis instance is equal to all instances ofImmutablePermissionWrapperthat have equal attribute values.inthashCode()Computes a hash code from attributes:permission.A permission.toString()Prints the immutable valuePermissionWrapperwith attribute values.withPermission(Permission value) Copy the current immutable object by setting a value for thepermissionattribute.
-
Method Details
-
permission
A permission.- Specified by:
permissionin interfacePermissionWrapper- Returns:
- A
Permission.
-
withPermission
Copy the current immutable object by setting a value for thepermissionattribute. A shallow reference equality check is used to prevent copying of the same value by returningthis.- Parameters:
value- A new value for permission- Returns:
- A modified copy of the
thisobject
-
equals
This instance is equal to all instances ofImmutablePermissionWrapperthat have equal attribute values. -
hashCode
public int hashCode()Computes a hash code from attributes:permission. -
toString
Prints the immutable valuePermissionWrapperwith attribute values. -
copyOf
Creates an immutable copy of aPermissionWrappervalue. 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 PermissionWrapper instance
-
builder
Creates a builder forImmutablePermissionWrapper.ImmutablePermissionWrapper.builder() .permission(org.xrpl.xrpl4j.model.transactions.Permission) // requiredpermission.build();- Returns:
- A new ImmutablePermissionWrapper builder
-