Package org.springframework.webflow.engine

Examples of org.springframework.webflow.engine.SubflowState


    private Flow createFlowWithSubflow(final String parentId, final String childId) {
        // Create a flow containing a subflow followed by a view state
        final Flow parent = new Flow(parentId);
        final Flow child = createSimpleFlow(childId);
        final ActionState state1 = new ActionState(parent, "state1-action");
        final SubflowState state2 = new SubflowState(parent, "state2-subflow", new StaticExpression(child));
        final ViewState state3 = new ViewState(parent, "state3-view", new MockViewFactory("parentview"));
        new EndState(parent, "state4-end");
        state1.getActionList().add(new MockAction("state1-result"));
        state1.getTransitionSet().add(new Transition(new DefaultTargetStateResolver("state2-subflow")));
        state2.getTransitionSet().add(new Transition(new DefaultTargetStateResolver("state3-view")));
        state3.getTransitionSet().add(new Transition(new DefaultTargetStateResolver("state4-end")));
        return parent;
    }
View Full Code Here


   * @return the fully initialized subflow state instance
   */
  public State createSubflowState(String id, Flow flow, Action[] entryActions, Expression subflow,
      SubflowAttributeMapper attributeMapper, Transition[] transitions,
      FlowExecutionExceptionHandler[] exceptionHandlers, Action[] exitActions, AttributeMap attributes) {
    SubflowState subflowState = new SubflowState(flow, id, subflow);
    if (attributeMapper != null) {
      subflowState.setAttributeMapper(attributeMapper);
    }
    configureCommonProperties(subflowState, entryActions, transitions, exceptionHandlers, exitActions, attributes);
    return subflowState;
  }
View Full Code Here

   * @return the fully initialized subflow state instance
   */
  public State createSubflowState(String id, Flow flow, Action[] entryActions, Expression subflow,
      SubflowAttributeMapper attributeMapper, Transition[] transitions,
      FlowExecutionExceptionHandler[] exceptionHandlers, Action[] exitActions, AttributeMap<?> attributes) {
    SubflowState subflowState = new SubflowState(flow, id, subflow);
    if (attributeMapper != null) {
      subflowState.setAttributeMapper(attributeMapper);
    }
    configureCommonProperties(subflowState, entryActions, transitions, exceptionHandlers, exitActions, attributes);
    return subflowState;
  }
View Full Code Here

TOP

Related Classes of org.springframework.webflow.engine.SubflowState

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.