List "tests['a']" or whatever you're using for keys--at least that's what I'd try first.
Joined: Jan 09, 2006
I tried that and I'm still having the same problem. I had thought that the bracket notation and the dot notation worked the same way with literal values, well it seems to be considering I'm getting the same result.
I found out the problem. It would seem that the reason the map was empty was because the map was being populated after the set method was called. I determined this by moving the System.out.print into the execute method and noticed the values were being populated. As a side note, it is nice to see that Struts2 auto detects the generics when populating the map.
Oh, you mean you were trying to see the value not in the action method itself, but in the setter? Yes, that wouldn't work--the action is instantiated etc. before the params interceptor is called. It's the params interceptor that sets the request parameters into the action properties--the map has to exist before it can have values put into it.
(Looking at your code I see that's what you were doing; I missed that the first time around--sorry!)
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com