Class HalFilterRequest

java.lang.Object
com.vonage.client.common.HalFilterRequest
All Implemented Interfaces:
QueryParamsRequest
Direct Known Subclasses:
ListApplicationRequest, ListConversationsRequest, ListEventsRequest, ListMembersRequest, ListUserConversationsRequest

public abstract class HalFilterRequest extends Object implements QueryParamsRequest
Provides basic filtering parameters for HAL resources.
Since:
8.4.0
  • Field Details

  • Constructor Details

  • Method Details

    • validatePage

      protected Integer validatePage(Integer page)
    • validatePageSize

      protected Integer validatePageSize(Integer pageSize)
    • makeParams

      Description copied from interface: QueryParamsRequest
      Internal method for serializing the fields of this class into query parameters. The Map should be mutable so that subclasses can add fields, otherwise the method or implementing class should be marked as final. Duplicate entries can be handled by mapping the key to a list of the entries.
      Specified by:
      makeParams in interface QueryParamsRequest
      Returns:
      The query parameters as unique key-value pairs.
    • getPage

      protected Integer getPage()
      Page number to navigate to in the response.
      Returns:
      The page as an integer, or null if not specified.
    • getPageSize

      protected Integer getPageSize()
      Number of results per page.
      Returns:
      The page size as an integer, or null if not specified.
    • getOrder

      protected SortOrder getOrder()
      Order to sort the results by.
      Returns:
      The result sort order as an enum, or null if not specified.
    • getStartDate

      protected Instant getStartDate()
      Filter records that occurred after this point in time.
      Returns:
      The start timestamp for results, or null if unspecified.
    • getEndDate

      protected Instant getEndDate()
      Filter records that occurred before this point in time.
      Returns:
      The end timestamp for results, or null if unspecified.
    • getCursor

      protected String getCursor()
      The cursor to start returning results from. This can be obtained from the URL in the relevant section from HalPageResponse.getLinks().
      Returns:
      The page navigation cursor as a string, or null if unspecified.