cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rainer Pruy <Rainer.P...@Acrys.COM>
Subject Re: JXPath selection lists and maps
Date Thu, 05 Jun 2008 08:54:24 GMT
Sorry,
but a map is *not* a collection.
(it is not drived from Collection base class)

You might try using the set of keys (.keySet()) or the collection of values (.values()) from
the map
according to your needs.

Rainer

Hans-Christian Meier schrieb:
> Hello,
> 
> I work with Cocoon 2.1.10 and JXPath selection lists. According to the
> API a MultiValueField accepts Java collections so I assume it also
> works with a Map.
> 
> In case of an ArrayList I can write widget.setSelectionList(array,
> ".", "."). When I try this with a Map I get an exception:
> java.lang.ClassCastException:
> java.util.TreeMapjava.util.TreeMapresource://org/apache/cocoon/forms/generation/jx-macros.xml
> - 6:1827
> Caused by: org.mozilla.javascript.WrappedException: Wrapped
> org.apache.cocoon.generation.JXTemplateGenerator$JXTException:
> java.util.TreeMap
> 
> Any ideas?
> 
> Thanks in advance!
> Hans
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message