From a12e2f92eff98664f57e3f1dd114903e2188c277 Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Wed, 8 Jan 2025 13:46:43 +0200 Subject: [PATCH] Use setItemsPageable --- .../main/java/com/vaadin/flow/component/grid/Grid.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/vaadin-grid-flow-parent/vaadin-grid-flow/src/main/java/com/vaadin/flow/component/grid/Grid.java b/vaadin-grid-flow-parent/vaadin-grid-flow/src/main/java/com/vaadin/flow/component/grid/Grid.java index 036f4b0cfe9..fde2f07571a 100755 --- a/vaadin-grid-flow-parent/vaadin-grid-flow/src/main/java/com/vaadin/flow/component/grid/Grid.java +++ b/vaadin-grid-flow-parent/vaadin-grid-flow/src/main/java/com/vaadin/flow/component/grid/Grid.java @@ -2967,7 +2967,7 @@ public interface CountCallback extends Serializable { * component will automatically fetch more items and adjust its size until * the backend runs out of items. Usage example: *

- * {@code component.setItemsSpring(pageable -> orderService.getOrders(pageable));} + * {@code component.setItemsPageable(pageable -> orderService.getOrders(pageable));} *

* The returned data view object can be used for further configuration, or * later on fetched with {@link #getLazyDataView()}. For using in-memory @@ -2979,7 +2979,7 @@ public interface CountCallback extends Serializable { * backend based on the given pageable * @return a data view for further configuration */ - public GridLazyDataView setItemsSpring( + public GridLazyDataView setItemsPageable( Spring.FetchCallback fetchCallback) { return setItems( query -> handleSpringFetchCallback(query, fetchCallback)); @@ -2992,7 +2992,7 @@ public GridLazyDataView setItemsSpring( * user benefits from the component showing immediately the exact size. * Usage example: *

- * {@code component.setItemsSpring( + * {@code component.setItemsPageable( * pageable -> orderService.getOrders(pageable), * pageable -> orderService.countOrders());} *

@@ -3008,7 +3008,7 @@ public GridLazyDataView setItemsSpring( * a function that returns the number of items in the back end * @return LazyDataView instance for further configuration */ - public GridLazyDataView setItemsSpring( + public GridLazyDataView setItemsPageable( Spring.FetchCallback fetchCallback, Spring.CountCallback countCallback) { return setItems(