Flash Scope and Flash variables in Spring MVC

Sometimes its nice to be able to transfer object between request or for flash messages without need for a whole session. Here we will use session as our store mechanism for our flash scope. This concept here can be extended into implementing a ‘Conversation Scope’ but that is a whole different animal.

Example Usage

 @FlashAttribute(TABNAME_ATTRIB)
 public String getTabName() {
   return tabObject;
 }

Leave a Comment

Your email address will not be published. Required fields are marked *