You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by Apache Wiki <wi...@apache.org> on 2009/08/12 11:26:35 UTC
[Tapestry Wiki] Update of "Tapestry5SelectObject" by MaximeCapelle
Dear Wiki user,
You have subscribed to a wiki page or wiki category on "Tapestry Wiki" for change notification.
The following page has been changed by MaximeCapelle:
http://wiki.apache.org/tapestry/Tapestry5SelectObject
The comment on the change is:
toValue doesn't work with Double (e.g). access.get() must be casted in String
------------------------------------------------------------------------------
public T toValue(String string) {
for (T obj : list) {
+ if (toClient(obj).equals(string)) return obj;
- if (fieldName == null) {
- if ((obj + "").equals(string)) {
- return obj;
- }
- } else {
- if (access.get(obj, fieldName).equals(string)) {
- return obj;
- }
- }
}
return null;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org