Package org.amplafi.flow

Examples of org.amplafi.flow.FlowState.finishFlow()


        invokeIfNotNull(cycle, getFinishListener(), getEndListener());

        FlowState currentFlowState = getAttachedFlowState();
        try {
            String page = currentFlowState.finishFlow();
            // because the new active flow can be very different
            FlowState newCurrentFlow = getFlowManagement().getCurrentFlowState();
            if ( newCurrentFlow != null ) {
                page = newCurrentFlow.getCurrentPage();
            } else {
View Full Code Here


                }
                String changed = "chg_"+name;
                flowState.setProperty(name, changed);
            }
        }
        flowState.finishFlow();
        FlowValuesMap<FlowValueMapKey, CharSequence> finalMap = flowState.getExportedValuesMap();
        // now make sure that only the properties allowed to be set externally are set.
        for (PropertyScope propertyScope: PropertyScope.values()) {
            for(PropertyUsage propertyUsage: PropertyUsage.values()) {
                String name= propertyScope+"_"+propertyUsage;
View Full Code Here

        flowActivity.addPropertyDefinitions(flowPropertyDefinition);
        String flowTypeName = flowTestingUtils.addFlowDefinition(flowActivity);
        FlowState flowState = flowTestingUtils.getFlowManagement().startFlowState(flowTypeName, false, null, null);
        flowState.setProperty("not-a-property", true);
        flowState.setProperty("testProp", true);
        flowState.finishFlow();
        FlowValuesMap exportedMap = flowState.getExportedValuesMap();
        assertEquals(exportedMap.get("testProp"), "true");
        assertFalse(exportedMap.containsKey("not-a-property"));
        assertEquals(exportedMap.size(), 1);
    }
View Full Code Here

        try {
            // should this be a force situation and ignore any errors? seems unlikely as Amplafi would want user to be able to save any half-finished changes.
            if (finishFlowId != null ) {
                flowState = getFlowManagement().getFlowState(finishFlowId);
                if ( flowState != null && !flowState.isCompleted()) {
                    pageName = flowState.finishFlow();
                }
            }
            if ( flowLauncher != null) {
                flowLauncher.setFlowManagement(getFlowManagement());
                if (flowLauncher instanceof StartFromDefinitionFlowLauncher) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.