Re: s:iterator get value to specific key

2010-11-03 Thread Emil Dombagolla
Hi all,

Thanks a lot  for the solutions.

Emil


On Wed, Nov 3, 2010 at 9:30 AM, Dale Newfield d...@newfield.org wrote:

 in Java you have two tools to get what you're asking for:

 Map has an entrySet() method returns a SetMap.Entry, each one of which
 has a getKey() and a getValue() method.
 The original map also has a get() method.

 So translating to ognl, you can iterate over map.entrySet(), and use
 top.key, top.value (or just key, value)...or wherever you have a key, you
 can always say map.get(key).

 -Dale


 -
 To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
 For additional commands, e-mail: user-h...@struts.apache.org




s:iterator get value to specific key

2010-11-02 Thread Emil Dombagolla
Dear all ,

Please please help me on this,

I have a map with iterator tag, i need to get a value for a specific key,
can i do this

s:iterator value=MAP

I want to say  s:property value=MAP['KEY'] /   ,  i expect VALUE for
the relevant key

 /s:iterator

Thanks Lot.
emil


Re: s:iterator get value to specific key

2010-11-02 Thread Matthias Rakowski

This should work:

s:iterator value=MAP

s:property value=KEY/

/s:iterator



s:iterator value=MAP

 I want to says:property value=MAP['KEY'] /,  i expect VALUE for
the relevant key

  /s:iterator


-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Re: s:iterator get value to specific key

2010-11-02 Thread Maurizio Cucchiara
You should be able to access on a specific map item through
s:property value=map.key/
or
s:property value=map['key']/

You also should be able to iterate through
s:iterator value=map
   s:property value=key/
   s:property value=value/
 /s:iterator


2010/11/2 Emil Dombagolla dombago...@gmail.com:
 Dear all ,

 Please please help me on this,

 I have a map with iterator tag, i need to get a value for a specific key,
 can i do this

 s:iterator value=MAP

    I want to say  s:property value=MAP['KEY'] /   ,  i expect VALUE for
 the relevant key

  /s:iterator

 Thanks Lot.
 emil




-- 
Maurizio Cucchiara

-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org



Re: s:iterator get value to specific key

2010-11-02 Thread Dale Newfield

in Java you have two tools to get what you're asking for:

Map has an entrySet() method returns a SetMap.Entry, each one of which 
has a getKey() and a getValue() method.

The original map also has a get() method.

So translating to ognl, you can iterate over map.entrySet(), and use 
top.key, top.value (or just key, value)...or wherever you have a key, 
you can always say map.get(key).


-Dale

-
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org