Interface CustomerPagedSearchResponse


public interface CustomerPagedSearchResponse
CustomerPagedSearchResponse
Example to create an instance using the builder pattern

     CustomerPagedSearchResponse customerPagedSearchResponse = CustomerPagedSearchResponse.builder()
             .total(0.3)
             .limit(0.3)
             .offset(0.3)
             .plusResults(resultsBuilder -> resultsBuilder)
             .build()
 
  • Method Details

    • getTotal

      @NotNull @NotNull Long getTotal()

      Total number of results matching the query.

      Returns:
      total
    • getLimit

      @NotNull @NotNull Integer getLimit()

      Number of results requested.

      Returns:
      limit
    • getOffset

      @NotNull @NotNull Integer getOffset()

      Number of elements skipped.

      Returns:
      offset
    • getResults

      @NotNull @Valid @NotNull @Valid List<CustomerSearchResult> getResults()

      Search result containing the Customers matching the search query.

      Returns:
      results
    • setTotal

      void setTotal(Long total)

      Total number of results matching the query.

      Parameters:
      total - value to be set
    • setLimit

      void setLimit(Integer limit)

      Number of results requested.

      Parameters:
      limit - value to be set
    • setOffset

      void setOffset(Integer offset)

      Number of elements skipped.

      Parameters:
      offset - value to be set
    • setResults

      void setResults(CustomerSearchResult... results)

      Search result containing the Customers matching the search query.

      Parameters:
      results - values to be set
    • setResults

      void setResults(List<CustomerSearchResult> results)

      Search result containing the Customers matching the search query.

      Parameters:
      results - values to be set
    • of

      factory method
      Returns:
      instance of CustomerPagedSearchResponse
    • of

      factory method to create a shallow copy CustomerPagedSearchResponse
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • deepCopy

      factory method to create a deep copy of CustomerPagedSearchResponse
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      builder factory method for CustomerPagedSearchResponse
      Returns:
      builder
    • builder

      create builder for CustomerPagedSearchResponse instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withCustomerPagedSearchResponse

      default <T> T withCustomerPagedSearchResponse(Function<CustomerPagedSearchResponse,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static com.fasterxml.jackson.core.type.TypeReference<CustomerPagedSearchResponse> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference