summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeemu Suo-Anttila <tsuoanttila@users.noreply.github.com>2016-12-14 16:48:38 +0200
committerIlia Motornyi <elmot@vaadin.com>2016-12-14 16:48:38 +0200
commit9c1cd9f8a71102a199a00af08f9d12c261cebe4c (patch)
tree5929dfab40d45569985eec2d1c364eced7dd6237
parent7391e7cebf01665a58d0604144c6384ccc23356a (diff)
downloadvaadin-framework-9c1cd9f8a71102a199a00af08f9d12c261cebe4c.tar.gz
vaadin-framework-9c1cd9f8a71102a199a00af08f9d12c261cebe4c.zip
Provide more extensive JavaDoc for DataProvider
-rw-r--r--server/src/main/java/com/vaadin/server/data/DataProvider.java15
1 files changed, 13 insertions, 2 deletions
diff --git a/server/src/main/java/com/vaadin/server/data/DataProvider.java b/server/src/main/java/com/vaadin/server/data/DataProvider.java
index ad6185b51a..5c60ca0951 100644
--- a/server/src/main/java/com/vaadin/server/data/DataProvider.java
+++ b/server/src/main/java/com/vaadin/server/data/DataProvider.java
@@ -22,12 +22,20 @@ import java.util.Objects;
import java.util.stream.Collectors;
import java.util.stream.Stream;
+import com.vaadin.data.Listing;
import com.vaadin.server.SerializableFunction;
import com.vaadin.shared.Registration;
/**
- * Minimal DataProvider API for communication between the DataProvider and a
- * back end service.
+ * A common interface for fetching data from a backend. The {@link DataProvider}
+ * interface is used by {@link Listing} components. The listing component will
+ * provide a {@link Query} object with request information, and the data
+ * provider uses this information to return a stream containing requested beans.
+ * <p>
+ * Vaadin comes with a ready-made solution for in-memory data, known as
+ * {@link ListDataProvider} which can be created using static {@code create}
+ * methods in this interface. For custom backends such as SQL, EntityManager,
+ * REST APIs or SpringData, use a {@link BackEndDataProvider} or its subclass.
*
* @author Vaadin Ltd.
*
@@ -36,6 +44,9 @@ import com.vaadin.shared.Registration;
* @param <F>
* filter type
*
+ * @see #create(Collection)
+ * @see #create(Stream)
+ * @see #create(Object...)
* @see ListDataProvider
* @see BackEndDataProvider
*