Class Page<T>

java.lang.Object
uno.anahata.ai.nb.model.Page<T>
Type Parameters:
T - The type of the items in the page.

public class Page<T> extends Object
A generic, self-contained container for a paginated result set. It encapsulates the logic for slicing a larger list into a single page.
  • Constructor Details

    • Page

      public Page(List<T> allItems, int startIndex, int pageSize)
      Creates a new Page object by slicing a complete list of items.
      Parameters:
      allItems - The complete list of items to be paginated.
      startIndex - The starting index (0-based) for the page.
      pageSize - The maximum number of items for the page.