Class SlackIconObject

java.lang.Object
com.hubspot.slack.client.models.blocks.objects.SlackIconObject
All Implemented Interfaces:
CompositionObject, SlackIconObjectIF

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

Use the builder to create immutable instances: SlackIconObject.builder(). Use the static factory method to create immutable instances: SlackIconObject.of().

  • Method Details

    • getType

      public String getType()
      Specified by:
      getType in interface SlackIconObjectIF
      Returns:
      The computed-at-construction value of the type attribute
    • getName

      public SlackIconName getName()
      Specified by:
      getName in interface SlackIconObjectIF
      Returns:
      The value of the name attribute
    • withName

      public final SlackIconObject withName(SlackIconName value)
      Copy the current immutable object by setting a value for the name attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for name
      Returns:
      A modified copy or the this object
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of SlackIconObject 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, name.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

      public static SlackIconObject of(SlackIconName name)
      Construct a new immutable SlackIconObject instance.
      Parameters:
      name - The value for the name attribute
      Returns:
      An immutable SlackIconObject instance
    • copyOf

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

      public static SlackIconObject.Builder builder()
      Creates a builder for SlackIconObject.
       SlackIconObject.builder()
          .setName(com.hubspot.slack.client.models.blocks.objects.SlackIconName) // required name
          .build();
       
      Returns:
      A new SlackIconObject builder