diff options
author | Leif Åstrand <legioth@gmail.com> | 2017-02-16 10:59:38 +0200 |
---|---|---|
committer | Pekka Hyvönen <pekka@vaadin.com> | 2017-02-16 10:59:38 +0200 |
commit | 3841ea1f7309b068a0407031a6e745a3a0736aca (patch) | |
tree | 67d42440552981a3a162afe9fe506ad9350a4f8a /server/src/main/java/com/vaadin | |
parent | 1891ffa6e1c4db8bc0d0f60eca255895a6448bdd (diff) | |
download | vaadin-framework-3841ea1f7309b068a0407031a6e745a3a0736aca.tar.gz vaadin-framework-3841ea1f7309b068a0407031a6e745a3a0736aca.zip |
Add javadoc clarification for DataProivder.refreshItem (#8585)
* Add javadoc clarification for DataProivder.refreshItem
Diffstat (limited to 'server/src/main/java/com/vaadin')
-rw-r--r-- | server/src/main/java/com/vaadin/data/provider/DataProvider.java | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/server/src/main/java/com/vaadin/data/provider/DataProvider.java b/server/src/main/java/com/vaadin/data/provider/DataProvider.java index 6a5f9c0bb3..2fee0eef84 100644 --- a/server/src/main/java/com/vaadin/data/provider/DataProvider.java +++ b/server/src/main/java/com/vaadin/data/provider/DataProvider.java @@ -93,6 +93,14 @@ public interface DataProvider<T, F> extends Serializable { * Refreshes the given item. This method should be used to inform all * {@link DataProviderListener DataProviderListeners} that an item has been * updated or replaced with a new instance. + * <p> + * For this to work properly, the item must either implement + * {@link #equals(Object)} and {@link #hashCode()} to consider both the old + * and the new item instances to be equal, or alternatively + * {@link #getId(Object)} should be implemented to return an appropriate + * identifier. + * + * @see #getId(Object) * * @param item * the item to refresh |