[jboss-user] [JBoss Seam] - feature idea - conversation names

matt.drees do-not-reply at jboss.com
Fri Aug 10 16:13:44 EDT 2007


Does anyone else think it'd be useful to let conversations have a logical name?
e.g.

  | <begin-conversation name="book room"/>
  | or
  | @begin(name="book room")
  | 

Then you could restrict which conversations components can run in.
e.g.

  | @Conversational(legalConversations={"book room", "modify booking"})
  | or maybe
  | <page>
  |    <legal-conversations>
  |       <name>book room</name>
  |       <name>modify booking</name>
  |    <legal-conversations>
  | ...
  | </page>
  | 

This would be particularly helpful for nested conversations.  E.g., say 'book room' sometimes has a child conversation 'room preferences', and say you don't want users to access roomPreferences.xhtml unless they're in the 'room preferences' conversation.  Note that conversation-required isn't helpful here, because there *is* a conversation, but it's the wrong one.  In this case, you could redirect to no-conversation-view-id, or maybe make a wrong-conversation-view-id attribute.


Note that this is just an idea I was thinking about; I haven't run into a business requirement for this.  And I think you could probably imitate most of this already with a conversation-scoped ConversationName component and page actions.  But the syntax seems handy.  And it seems like your code might be more self-documenting this way, and it would probably help identify programmer errors more quickly (I've had some frustrating debugging sessions resulting from components being put in a parent conversation instead of the child one).


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

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



More information about the jboss-user mailing list