diff options
author | Leif Åstrand <leif@vaadin.com> | 2012-05-11 11:31:58 +0300 |
---|---|---|
committer | Leif Åstrand <leif@vaadin.com> | 2012-05-11 11:31:58 +0300 |
commit | bb5fca1bcaaa114175c45bf0e4d78a53ccee6c8a (patch) | |
tree | 89bcd150817c2b1cb355a364baa0212c968ba7a7 | |
parent | 2b4abbe715a278146d2d53f0d75b4ec1a47506dd (diff) | |
download | vaadin-framework-bb5fca1bcaaa114175c45bf0e4d78a53ccee6c8a.tar.gz vaadin-framework-bb5fca1bcaaa114175c45bf0e4d78a53ccee6c8a.zip |
Improved error message
-rw-r--r-- | src/com/vaadin/data/util/IndexedContainer.java | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/com/vaadin/data/util/IndexedContainer.java b/src/com/vaadin/data/util/IndexedContainer.java index 1e0a2fae1a..bcaa5eda42 100644 --- a/src/com/vaadin/data/util/IndexedContainer.java +++ b/src/com/vaadin/data/util/IndexedContainer.java @@ -865,7 +865,6 @@ public class IndexedContainer extends * @see com.vaadin.data.Property#setValue(java.lang.Object) */ public void setValue(Object newValue) throws Property.ReadOnlyException { - // Gets the Property set final Map<Object, Object> propertySet = items.get(itemId); @@ -875,8 +874,10 @@ public class IndexedContainer extends } else if (getType().isAssignableFrom(newValue.getClass())) { propertySet.put(propertyId, newValue); } else { - throw new IllegalArgumentException("Value is of invalid type, " - + getType().getName() + " expected"); + throw new IllegalArgumentException( + "Value is of invalid type, got " + + newValue.getClass().getName() + " but " + + getType().getName() + " was expected"); } // update the container filtering if this property is being filtered |