When you are talking about action messages it is not a hash map with a key. 
It is a simple Collection<String>.  ActionSupport has a method
getActionMessages() that returns this string collection.

Field errors are a different matter.  These come through as a Map<String,
List<String>>.  You get that map through getFieldErrors().




luy wrote:
> 
> Good afternoon,
> 
> I'd like to know
> (1) how to get all action messages in java code
> (2) How to remove some action message from ActionMessages
> 
> 
> Something like (1) returns
> 
> ActionMessage("key1")
> ActionMessage("key2")
> ...
> 
> ActionMessage("keyN")
> 
> 
> (2) removes key1...key9
> 
> Thanks a lot!
> -- 
> Lu Ying
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail: user-h...@struts.apache.org
> 
> 
> 

-- 
View this message in context: 
http://old.nabble.com/How-to-retrieve-all-action-messages-in-java-code-tp28196001p28213359.html
Sent from the Struts - User mailing list archive at Nabble.com.


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

Reply via email to