Class PagelessDataCommunicator<T>
- java.lang.Object
-
- com.vaadin.flow.data.provider.DataCommunicator<T>
-
- com.vaadin.flow.component.virtuallist.paging.PagelessDataCommunicator<T>
-
- Type Parameters:
T- item type
- All Implemented Interfaces:
Serializable
public class PagelessDataCommunicator<T> extends DataCommunicator<T>
DataCommunicator implementation which disables the paging and does not allow the user to set up the page for VirtualList.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.vaadin.flow.data.provider.DataCommunicator
DataCommunicator.EmptyDataProvider<T1>, DataCommunicator.Filter<F>
-
-
Field Summary
-
Fields inherited from class com.vaadin.flow.data.provider.DataCommunicator
DEFAULT_PAGE_INCREASE_COUNT
-
-
Constructor Summary
Constructors Constructor Description PagelessDataCommunicator(DataGenerator<T> dataGenerator, ArrayUpdater arrayUpdater, SerializableConsumer<elemental.json.JsonArray> dataUpdater, StateNode stateNode)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisPagingEnabled()Returns whether paged queries are enabled or not.voidsetPageSize(int pageSize)Sets the page size that is used to fetch items.voidsetPagingEnabled(boolean pagingEnabled)Sets whether paged queries or offset/limit queries will be used.-
Methods inherited from class com.vaadin.flow.data.provider.DataCommunicator
buildQuery, computeRequestedRange, confirmUpdate, enablePushUpdates, fetchFromProvider, getBackEndSorting, getDataProvider, getDataProviderSize, getFilter, getInMemorySorting, getItem, getItemCount, getItemCountEstimate, getItemCountEstimateIncrease, getKeyMapper, getPageSize, getPassivatedKeys, handleDataRefreshEvent, isDefinedSize, isFetchEnabled, isItemActive, refresh, reset, setBackEndSorting, setCountCallback, setDataProvider, setDataProvider, setDefinedSize, setFetchEnabled, setInMemorySorting, setItemCountEstimate, setItemCountEstimateIncrease, setKeyMapper, setRequestedRange
-
-
-
-
Constructor Detail
-
PagelessDataCommunicator
public PagelessDataCommunicator(DataGenerator<T> dataGenerator, ArrayUpdater arrayUpdater, SerializableConsumer<elemental.json.JsonArray> dataUpdater, StateNode stateNode)
-
-
Method Detail
-
setPageSize
public void setPageSize(int pageSize)
Description copied from class:DataCommunicatorSets the page size that is used to fetch items. The queries to data provider are a multiple of the page size.- Overrides:
setPageSizein classDataCommunicator<T>- Parameters:
pageSize- the page size to set
-
setPagingEnabled
public void setPagingEnabled(boolean pagingEnabled)
Description copied from class:DataCommunicatorSets whether paged queries or offset/limit queries will be used.- Overrides:
setPagingEnabledin classDataCommunicator<T>- Parameters:
pagingEnabled-truefor paged queries,falsefor offset/limit queries
-
isPagingEnabled
public boolean isPagingEnabled()
Description copied from class:DataCommunicatorReturns whether paged queries are enabled or not.When the paged queries are supported, the
Query.getPage()andQuery.getPageSize()can be used to fetch items from the paged repositories. Otherwise, one should useQuery.getOffset()andQuery.getLimit(). Paged queries are enabled by default.- Overrides:
isPagingEnabledin classDataCommunicator<T>- Returns:
truefor paged queries,falsefor offset/limit queries- See Also:
DataCommunicator.setPagingEnabled(boolean)
-
-