Class UsersSelectInput

java.lang.Object
com.hubspot.slack.client.models.interaction.views.UsersSelectInput
All Implemented Interfaces:
UsersSelectInputIF, ViewInput

@Generated(from="UsersSelectInputIF", generator="Immutables") @ParametersAreNonnullByDefault @Generated("org.immutables.processor.ProxyProcessor") @Immutable public final class UsersSelectInput extends Object implements UsersSelectInputIF
Immutable implementation of UsersSelectInputIF.

Use the builder to create immutable instances: UsersSelectInput.builder().

  • Method Details

    • getType

      public ViewInputType getType()
      Specified by:
      getType in interface ViewInput
      Returns:
      The value of the type attribute
    • getSelectedUser

      public Optional<String> getSelectedUser()
      Specified by:
      getSelectedUser in interface UsersSelectInputIF
      Returns:
      The value of the selectedUser attribute
    • withType

      public final UsersSelectInput withType(ViewInputType value)
      Copy the current immutable object by setting a value for the type attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for type
      Returns:
      A modified copy or the this object
    • withSelectedUser

      public final UsersSelectInput withSelectedUser(@Nullable String value)
      Copy the current immutable object by setting a present value for the optional selectedUser attribute.
      Parameters:
      value - The value for selectedUser, null is accepted as java.util.Optional.empty()
      Returns:
      A modified copy or this if not changed
    • withSelectedUser

      public final UsersSelectInput withSelectedUser(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the selectedUser attribute. An equality check is used on inner value to prevent copying of the same value by returning this.
      Parameters:
      optional - An optional value for selectedUser
      Returns:
      A modified copy or this if not changed
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of UsersSelectInput that have equal attribute values.
      Overrides:
      equals in class Object
      Returns:
      true if this is equal to another instance
    • hashCode

      public int hashCode()
      Computes a hash code from attributes: type, selectedUser.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

      public String toString()
      Prints the immutable value UsersSelectInput with attribute values.
      Overrides:
      toString in class Object
      Returns:
      A string representation of the value
    • copyOf

      public static UsersSelectInput copyOf(UsersSelectInputIF instance)
      Creates an immutable copy of a UsersSelectInputIF 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 UsersSelectInput instance
    • builder

      public static UsersSelectInput.Builder builder()
      Creates a builder for UsersSelectInput.
       UsersSelectInput.builder()
          .setType(com.hubspot.slack.client.models.interaction.views.ViewInputType) // required type
          .setSelectedUser(Optional<String>) // optional selectedUser
          .build();
       
      Returns:
      A new UsersSelectInput builder