2007/5/30, Sven Schliesing <[EMAIL PROTECTED]>:

Changing the code to:
new ListView("list", new ArrayList<Map.Entry<IKey,
Integer>>(map.entrySet())) {
    public void populateItem(ListItem listItem) {
      Map.Entry<IKey, Integer> entry = (Map.Entry<IKey, Integer>)
listItem.getModelObject();
      ...
    }
};

doesn't fix the problem. Furthermore
http://java.sun.com/j2se/1.5.0/docs/api/java/util/Map.html says that
Maps are not serializable. Now I'm confused.

btw: I didn't make the variable final to use it in an inner class. It
was just a leftover of c&p.


I don't know exactly how to fix the problem, but that's right,
Map.Entryaren't serializable.
The Map are serializable if the content is serializable. But when you
serializes a map, only keys and values are serialized, not the entries (that
are rebuilt when unserializing the map). So maybe you should create ( or use
if there is one) a Model that uses your map directly.

Matthieu
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to