Package bucket.core

Interface PaginationSupport<T>

Type Parameters:
T - - the type of the item
All Known Implementing Classes:
ListBuilderPaginationSupport, ManualTotalPaginationSupport, PagerPaginationSupport, PaginationSupport, PaginationSupportAdaptor, UsernameToUserTranslatingPaginationSupport

@Deprecated public interface PaginationSupport<T>
Deprecated.
since 6.10.0. Use PaginationService instead.
Calculates the page values and indexes for a list of items
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Deprecated.
    Returns the next start index.
    int[]
    Deprecated.
    Returns an array of start indexes for pages that appear after the current page If there are no further pages, null is returned
    int
    Deprecated.
    Returns an end index for use in the UI.
    int
    Deprecated.
    Returns a start index for use in the UI.
    Deprecated.
    Returns a sub-list of items that are shown on the page.
    int
    Deprecated.
    Returns the number of items available on the current page.
    int
    Deprecated.
    Returns the previous start index.
    int[]
    Deprecated.
    Returns an array of start indexes for pages that appear before the current page If there are no preceding pages, null is returned
    int
    Deprecated.
    Returns the start index.
    int
    Deprecated.
    Always return the start index value, regardless of whether the pagination has any total.
    int
    Deprecated.
    Returns the total number of items in the list
  • Method Details

    • getStartIndex

      int getStartIndex()
      Deprecated.
      Returns the start index. If the start index exceeds the index of the last element, the index of the last element is returned. If the start index is less than 0, 0 is returned.
      Returns:
      the start index.
    • getNiceStartIndex

      int getNiceStartIndex()
      Deprecated.
      Returns a start index for use in the UI. It returns the start index + 1
      Returns:
      a nice start index
    • getTotal

      int getTotal()
      Deprecated.
      Returns the total number of items in the list
      Returns:
      total number of items in the list
    • getPage

      List<T> getPage()
      Deprecated.
      Returns a sub-list of items that are shown on the page.
      Returns:
      a sub-list of items that are available on the page.
    • getStartIndexValue

      int getStartIndexValue()
      Deprecated.
      Always return the start index value, regardless of whether the pagination has any total.
      Returns:
      the start index value, regardless of whether the pagination has any total.
    • getNextStartIndex

      int getNextStartIndex()
      Deprecated.
      Returns the next start index. Returns -1 if we are on the last page (there is no next page).
      Returns:
      the next start index. Returns -1 if we are on the last page (there is no next page).
    • getPreviousStartIndex

      int getPreviousStartIndex()
      Deprecated.
      Returns the previous start index. Returns -1 if we are on the first page (there is no previous page).
      Returns:
      the previous start index. Returns -1 if we are on the first page (there is no previous page).
    • getNextStartIndexes

      int[] getNextStartIndexes()
      Deprecated.
      Returns an array of start indexes for pages that appear after the current page If there are no further pages, null is returned
      Returns:
      an array of start indexes for pages that appear after the current page
    • getPreviousStartIndexes

      int[] getPreviousStartIndexes()
      Deprecated.
      Returns an array of start indexes for pages that appear before the current page If there are no preceding pages, null is returned
      Returns:
      an array of start indexes for pages that appear before the current page
    • getNiceEndIndex

      int getNiceEndIndex()
      Deprecated.
      Returns an end index for use in the UI. It returns the end index - 1
      Returns:
      a nice end index
    • getPageSize

      int getPageSize()
      Deprecated.
      Returns the number of items available on the current page.
      Returns:
      the number of items available on the current page.