public class PaginatedList<E>
extends com.google.common.collect.ForwardingList<E>
| Modifier and Type | Class and Description |
|---|---|
static class |
PaginatedList.PaginationInfo |
| Constructor and Description |
|---|
PaginatedList(List<E> delegate,
int total,
int page,
int perPage)
Creates a PaginatedList
|
PaginatedList(List<E> delegate,
int total,
int page,
int perPage,
Long grandTotal)
Creates a PaginatedList
|
| Modifier and Type | Method and Description |
|---|---|
List<E> |
delegate() |
static <T> PaginatedList<T> |
emptyList(int page,
int perPage) |
boolean |
equals(Object o) |
Optional<Long> |
grandTotal() |
int |
hashCode() |
PaginatedList.PaginationInfo |
pagination() |
static <T> PaginatedList<T> |
singleton(T entry,
int page,
int perPage) |
String |
toString() |
add, addAll, get, indexOf, lastIndexOf, listIterator, listIterator, remove, set, standardAdd, standardAddAll, standardEquals, standardHashCode, standardIndexOf, standardIterator, standardLastIndexOf, standardListIterator, standardListIterator, standardSubList, subListadd, addAll, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, retainAll, size, standardAddAll, standardClear, standardContains, standardContainsAll, standardIsEmpty, standardRemove, standardRemoveAll, standardRetainAll, standardToArray, standardToArray, standardToString, toArray, toArrayclone, finalize, getClass, notify, notifyAll, wait, wait, waitadd, addAll, clear, contains, containsAll, isEmpty, iterator, remove, removeAll, replaceAll, retainAll, size, sort, spliterator, toArray, toArrayparallelStream, removeIf, streampublic PaginatedList(@Nonnull List<E> delegate, int total, int page, int perPage)
delegate - the actual entriestotal - the count of all entries (ignoring pagination)page - the page this PaginatedList representsperPage - the size limit for each pagepublic PaginatedList(@Nonnull List<E> delegate, int total, int page, int perPage, Long grandTotal)
delegate - the actual entriestotal - the count of all entries (ignoring pagination)page - the page this PaginatedList representsperPage - the size limit for each pagegrandTotal - the count of all entries (ignoring query filters and pagination)public List<E> delegate()
delegate in class com.google.common.collect.ForwardingList<E>public PaginatedList.PaginationInfo pagination()
public boolean equals(Object o)
public int hashCode()
public String toString()
toString in class com.google.common.collect.ForwardingObjectpublic static <T> PaginatedList<T> emptyList(int page, int perPage)
public static <T> PaginatedList<T> singleton(T entry, int page, int perPage)
Copyright © 2012–2021 Graylog, Inc.. All rights reserved.