[jboss-user] [JBoss Seam] - Re: Beginning conversations in @Factory methods

petemuir do-not-reply at jboss.com
Wed Jul 12 15:03:59 EDT 2006


anonymous wrote : 
  | My problem is that the next action after a list is displayed is often displaying a selection from the list. As I understand things, on a postback the DataTable component will reaccess the DataModel through EL variable resolution, then indicate the row selected. If the DataModel exists in a long running conversation, that will be returned and it'll work great. If the conversation wasn't started when the original DataModel was generated I'd imagine a new DataModel will be created on the postback (through the @Factory method) and it could be different from what was rendered to the user. Does that make sense?
  | 


Yes, but if it's in PAGE scope then on 'postback' the datamodel will be available through EL so won't be recreated.  Your scenario is a big reason for PAGE scope :)

anonymous wrote : 
  | 2.1.3. Page context
  | 
  | The page context allows you to associate state with a particular instance of a rendered page. You can initialize state in your event listener, or while actually rendering the page, and then have access to it from any event that originates from that page. This is especially useful for functionality like clickable lists, where the list is backed by changing data on the server side. The state is actually serialized to the client, so this construct is extremely robust with respect to multi-window operation and the back button. 
  | 

A page action would work as well I think.  Remember you can disable conversation propogation for actions and therefore @Begin would start a new conversation. This is equivalent to to your 'stripping the conversation Id'.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3957473#3957473

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3957473



More information about the jboss-user mailing list