You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by Apache Wiki <wi...@apache.org> on 2005/08/06 12:23:33 UTC

[Myfaces Wiki] Update of "SaveState" by WernerPunz

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Myfaces Wiki" for change notification.

The following page has been changed by WernerPunz:
http://wiki.apache.org/myfaces/SaveState

The comment on the change is:
added additional data and links regarding dialog systems compared to x:saveState

------------------------------------------------------------------------------
  }}}
  
  on page 2 should restore the entered data from page1 at the beginning of the phase cycles.
- thus once you reference scopebean on page2 you will get the values from page1.
+ thus once you reference scopebean on page2 you will get the values from page1, before the value
+ of the submit are applied to the bean (if at all).
+ 
  You can do this for as many pages as you want. The scopebean is dropped from the cycle
  the moment the user runs into a page without a save_state statement.
  
- === Advantages === 
+ Thus you get a session like behavior on the scopebean without having
+ to put the scopebean into the session.
+ 
+ The usage example for such a mechanism is a wizard or some kind of dialog system.
+ The mechanism is comparable to such systems, but muche easier to use and limited
+ to the component level.
+ 
+ Alternate systems which use similar mechanisms are
+ 
+ * struts shale dialog
+ 
+ * [www.springframework.org spring dialog]
+ 
+ and probably a bunch of other systems.
+ Note, dialog systems go far beyound the x:saveState component, as such as they introduce another layer
+ of pageflow into the system, while x:saveState can be seen as quickly to implement solution to the problem
+ of having to keep data over multiple pages.
+ 
+ === Advantages of x:saveState over session scope === 
  
  It is safer, because you do not have to explicetly drop the objects. 
  And you do not put extra burden on the session.