You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by arne anka <do...@ginguppin.de> on 2008/05/26 15:14:18 UTC

dataList with Map

hi,
i am sure i miss something, but how do i make dataList work with a  
Map<String, String>
assume, the map's content is like
a=A
b=B

i would like the dataList to output
A(a)
B(b)

thanks in advance.

Re: dataList with Map

Posted by Christopher Cudennec <Sm...@gmx.net>.
Hi Arne,

maybe somebody has another solution but I'm pretty sure you get problems 
because there are no proper getter methods for java.util.Map. Try 
implementing a getter in your backing bean returning the keySet() of 
your map and another one returning the map itself. You can access your 
map by using #{bean.map[var]} if "var" is your dataList-var-name.

Cheers,

Christopher

arne anka schrieb:
> hi,
> i am sure i miss something, but how do i make dataList work with a 
> Map<String, String>
> assume, the map's content is like
> a=A
> b=B
>
> i would like the dataList to output
> A(a)
> B(b)
>
> thanks in advance.
> ------------------------------------------------------------------------
>
>
> No virus found in this incoming message.
> Checked by AVG. 
> Version: 8.0.100 / Virus Database: 269.24.1/1466 - Release Date: 25.05.2008 18:49
>