Browse Source

Add javadoc clarification for DataProivder.refreshItem (#8585)

* Add javadoc clarification for DataProivder.refreshItem
tags/8.1.0.alpha1
Leif Åstrand 7 years ago
parent
commit
3841ea1f73
1 changed files with 8 additions and 0 deletions
  1. 8
    0
      server/src/main/java/com/vaadin/data/provider/DataProvider.java

+ 8
- 0
server/src/main/java/com/vaadin/data/provider/DataProvider.java View File

@@ -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

Loading…
Cancel
Save