0 Replies Latest reply on May 8, 2007 11:56 AM by Andy Gibson

    Do we need both start-state/start-page pageflows?

    Andy Gibson Novice

      I've been playing around with the notion of a RESTFul URL that starts a conversation.

      The most obvious place to start a conversation for a restful URL is in pages.xml with the <begin-conversation join="true" pageflow="MyEdit"> tag in the edit page. The pageflow requires the flow to start with the start-page tag.

      However, the edit page might be called from places other than the bookmarked URL, and we might want to run the flow in a nested conversation. On that basis, we might start the flow from a @Begin annotated method, or an s:link, one of which requires the pageflow to start with a start-state tag.

      The problem is that I need to write two almost identical page flows, one with start-state and the other with start-page as the first tag.

      Is there really a need for both types? In 99% of cases the flows will be identical with the start-state re-directing to the same page specified as the start-page. In the event of you really needing two different pageflows depending on the origin of the pageflows start, you have the option of writing two pageflows, which you would have to anyway under the current design. Seam certainly knows which to expect on the basis that it will tell you when you are calling the wrong pageflow type.