This content has been marked as final.
Show 3 replies
-
1. Re: non-deterministic use case and conversation management
kapitanpetko Jun 18, 2009 3:51 AM (in response to gonorrhea)I've found out that using pages.xml for cases like this makes your life a lot easier. @Begin and @End are overrated anyways.
So I have no @End's, and starting a different use case destroys the current conversation. That is done in pages.xml like this:
before-redirect clears all 'leftovers' from your previous usecase, so you can both start with a clean state and free up some
memory.<rule if-outcome="usecase1"> <end-conversation before-redirect="true" /> <redirect view-id="/usecase1.xhtml" /> </rule> <rule if-outcome="usecase2"> <end-conversation before-redirect="true" /> <redirect view-id="/usecase2.xhtml" /> </rule>
HTH
-
2. Re: non-deterministic use case and conversation management
gonorrhea Jun 18, 2009 6:11 AM (in response to gonorrhea)how do you start (promote) the temp conversation to LRC?
and does if-outcome value correspond to a returned String from a business method??
-
3. Re: non-deterministic use case and conversation management
kapitanpetko Jun 19, 2009 3:51 AM (in response to gonorrhea)
Arbi Sookazian wrote on Jun 18, 2009 06:11:
how do you start (promote) the temp conversation to LRC?I use @Begin (usually) with a page action for this.
Here loadStuff is annotated with @Begin:<page view-id="/usecase2.xhtml"> <action on-postback="false" execute="#{manager.loadStuff}" />
and does if-outcome value correspond to a returned String from a business method??Yes. Although sometimes just a link is enough:
<s:link action="usecase2" value="UseCase2" />