Class SearchMessagesParams

java.lang.Object
com.hubspot.slack.client.methods.params.search.SearchMessagesParams
All Implemented Interfaces:
SearchMessagesParamsIF

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

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

  • Method Details

    • getQuery

      public String getQuery()
      Specified by:
      getQuery in interface SearchMessagesParamsIF
      Returns:
      The value of the query attribute
    • shouldHighlight

      public boolean shouldHighlight()
      Specified by:
      shouldHighlight in interface SearchMessagesParamsIF
      Returns:
      The value of the shouldHighlight attribute
    • getCount

      public int getCount()
      Specified by:
      getCount in interface SearchMessagesParamsIF
      Returns:
      The value of the count attribute
    • getPage

      public int getPage()
      Specified by:
      getPage in interface SearchMessagesParamsIF
      Returns:
      The value of the page attribute
    • getSort

      public ResultSort getSort()
      Specified by:
      getSort in interface SearchMessagesParamsIF
      Returns:
      The value of the sort attribute
    • getSortOrder

      public ResultSortOrder getSortOrder()
      Specified by:
      getSortOrder in interface SearchMessagesParamsIF
      Returns:
      The value of the sortOrder attribute
    • withQuery

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

      public final SearchMessagesParams withShouldHighlight(boolean value)
      Copy the current immutable object by setting a value for the shouldHighlight attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for shouldHighlight
      Returns:
      A modified copy or the this object
    • withCount

      public final SearchMessagesParams withCount(int value)
      Copy the current immutable object by setting a value for the count attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for count
      Returns:
      A modified copy or the this object
    • withPage

      public final SearchMessagesParams withPage(int value)
      Copy the current immutable object by setting a value for the page attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for page
      Returns:
      A modified copy or the this object
    • withSort

      public final SearchMessagesParams withSort(ResultSort value)
      Copy the current immutable object by setting a value for the sort attribute. A value equality check is used to prevent copying of the same value by returning this.
      Parameters:
      value - A new value for sort
      Returns:
      A modified copy or the this object
    • withSortOrder

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

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

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

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

      public static SearchMessagesParams.Builder builder()
      Creates a builder for SearchMessagesParams.
       SearchMessagesParams.builder()
          .setQuery(String) // required query
          .setShouldHighlight(boolean) // optional shouldHighlight
          .setCount(int) // optional count
          .setPage(int) // optional page
          .setSort(com.hubspot.slack.client.methods.ResultSort) // optional sort
          .setSortOrder(com.hubspot.slack.client.methods.ResultSortOrder) // optional sortOrder
          .build();
       
      Returns:
      A new SearchMessagesParams builder