Class BookmarksAddParams

java.lang.Object
com.hubspot.slack.client.methods.params.bookmarks.BookmarksAddParams
All Implemented Interfaces:
HasChannel, BookmarksAddParamsIF

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

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

  • Method Details

    • getChannelId

      public String getChannelId()
      Specified by:
      getChannelId in interface HasChannel
      Returns:
      The value of the channelId attribute
    • getChannel

      public String getChannel()
      Specified by:
      getChannel in interface BookmarksAddParamsIF
      Returns:
      The computed-at-construction value of the channel attribute
    • getTitle

      public String getTitle()
      Specified by:
      getTitle in interface BookmarksAddParamsIF
      Returns:
      The value of the title attribute
    • getType

      public BookmarkType getType()
      Specified by:
      getType in interface BookmarksAddParamsIF
      Returns:
      The value of the type attribute
    • getEmoji

      public Optional<String> getEmoji()
      Specified by:
      getEmoji in interface BookmarksAddParamsIF
      Returns:
      The value of the emoji attribute
    • getEntityId

      public Optional<String> getEntityId()
      Specified by:
      getEntityId in interface BookmarksAddParamsIF
      Returns:
      The value of the entityId attribute
    • getLink

      public Optional<String> getLink()
      Specified by:
      getLink in interface BookmarksAddParamsIF
      Returns:
      The value of the link attribute
    • getParentId

      public Optional<String> getParentId()
      Specified by:
      getParentId in interface BookmarksAddParamsIF
      Returns:
      The value of the parentId attribute
    • withChannelId

      public final BookmarksAddParams withChannelId(String value)
      Copy the current immutable object by setting a value for the channelId attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for channelId
      Returns:
      A modified copy or the this object
    • withTitle

      public final BookmarksAddParams withTitle(String value)
      Copy the current immutable object by setting a value for the title attribute. An equals check used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for title
      Returns:
      A modified copy or the this object
    • withType

      public final BookmarksAddParams withType(BookmarkType 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
    • withEmoji

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

      public final BookmarksAddParams withEmoji(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the emoji 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 emoji
      Returns:
      A modified copy or this if not changed
    • withEntityId

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

      public final BookmarksAddParams withEntityId(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the entityId 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 entityId
      Returns:
      A modified copy or this if not changed
    • withLink

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

      public final BookmarksAddParams withLink(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the link 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 link
      Returns:
      A modified copy or this if not changed
    • withParentId

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

      public final BookmarksAddParams withParentId(Optional<String> optional)
      Copy the current immutable object by setting an optional value for the parentId 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 parentId
      Returns:
      A modified copy or this if not changed
    • equals

      public boolean equals(@Nullable Object another)
      This instance is equal to all instances of BookmarksAddParams 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: channelId, channel, title, type, emoji, entityId, link, parentId.
      Overrides:
      hashCode in class Object
      Returns:
      hashCode value
    • toString

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

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

      public static BookmarksAddParams.Builder builder()
      Creates a builder for BookmarksAddParams.
       BookmarksAddParams.builder()
          .setChannelId(String) // required channelId
          .setTitle(String) // required title
          .setType(com.hubspot.slack.client.models.bookmarks.BookmarkType) // required type
          .setEmoji(Optional<String>) // optional emoji
          .setEntityId(Optional<String>) // optional entityId
          .setLink(Optional<String>) // optional link
          .setParentId(Optional<String>) // optional parentId
          .build();
       
      Returns:
      A new BookmarksAddParams builder