/** * Sets system attributes to be associated with the flow execution the next time one is started. by this test. * Useful for assigning attributes that influence flow execution behavior. * @param executionAttributes the system attributes to assign */ protected void setFlowExecutionAttributes(AttributeMap<Object> executionAttributes) { getFlowExecutionImplFactory().setExecutionAttributes(executionAttributes); }
private FlowExecutionImplFactory createFlowExecutionFactory(AttributeMap<Object> executionAttributes) { FlowExecutionImplFactory executionFactory = new FlowExecutionImplFactory(); executionFactory.setExecutionAttributes(executionAttributes); if (flowExecutionListenerLoader != null) { executionFactory.setExecutionListenerLoader(flowExecutionListenerLoader); } return executionFactory; }
private FlowExecutionImplFactory getExecutionFactory() { FlowExecutionImplFactory executionFactory = new FlowExecutionImplFactory(); executionFactory.setExecutionAttributes(getExecutionAttributes()); if (this.listenerLoader != null) { executionFactory.setExecutionListenerLoader(this.listenerLoader); } return executionFactory; }
/** * Sets system attributes to be associated with the flow execution the next time one is started. by this test. * Useful for assigning attributes that influence flow execution behavior. * @param executionAttributes the system attributes to assign */ protected void setFlowExecutionAttributes(AttributeMap executionAttributes) { getFlowExecutionImplFactory().setExecutionAttributes(executionAttributes); }
/** * Sets system attributes to be associated with the flow execution the next time one is started. by this test. * Useful for assigning attributes that influence flow execution behavior. * @param executionAttributes the system attributes to assign */ protected void setFlowExecutionAttributes(AttributeMap<Object> executionAttributes) { getFlowExecutionImplFactory().setExecutionAttributes(executionAttributes); }
/** * Sets system attributes to be associated with the flow execution the next time one is {@link #startFlow() started} * by this test. Useful for assigning attributes that influence flow execution behavior. * @param executionAttributes the system attributes to assign */ protected void setFlowExecutionAttributes(AttributeMap executionAttributes) { getFlowExecutionImplFactory().setExecutionAttributes(executionAttributes); }
private FlowExecutionImplFactory createFlowExecutionFactory(AttributeMap executionAttributes) { FlowExecutionImplFactory executionFactory = new FlowExecutionImplFactory(); executionFactory.setExecutionAttributes(executionAttributes); if (flowExecutionListenerLoader != null) { executionFactory.setExecutionListenerLoader(flowExecutionListenerLoader); } return executionFactory; }
private FlowExecutionImplFactory createFlowExecutionFactory(AttributeMap<Object> executionAttributes) { FlowExecutionImplFactory executionFactory = new FlowExecutionImplFactory(); executionFactory.setExecutionAttributes(executionAttributes); if (flowExecutionListenerLoader != null) { executionFactory.setExecutionListenerLoader(flowExecutionListenerLoader); } return executionFactory; }
/** * Create the flow execution factory to be used by the executor produced by this factory bean. Configure the * execution factory appropriately. Subclasses may override if they which to use a custom execution factory, e.g. to * use a custom FlowExecution implementation. * @param executionAttributes execution attributes to apply to created executions * @param executionListenerLoader decides which listeners to apply to created executions * @return a new flow execution factory instance */ protected FlowExecutionFactory createFlowExecutionFactory(AttributeMap executionAttributes, FlowExecutionListenerLoader executionListenerLoader) { FlowExecutionImplFactory executionFactory = new FlowExecutionImplFactory(); executionFactory.setExecutionAttributes(executionAttributes); if (executionListenerLoader != null) { executionFactory.setExecutionListenerLoader(executionListenerLoader); } return executionFactory; }
private FlowExecutionImplFactory getExecutionFactory() { FlowExecutionImplFactory executionFactory = new FlowExecutionImplFactory(); executionFactory.setExecutionAttributes(getExecutionAttributes()); if (this.listenerLoader != null) { executionFactory.setExecutionListenerLoader(this.listenerLoader); } return executionFactory; }
public void testCreateWithExecutionAttributes() { MutableAttributeMap<Object> attributes = new LocalAttributeMap<>(); attributes.put("foo", "bar"); factory.setExecutionAttributes(attributes); FlowExecution execution = factory.createFlowExecution(flowDefinition); assertEquals(attributes, execution.getAttributes()); assertSame("Flow execution attributes are global", attributes.asMap(), execution.getAttributes().asMap()); }
public void testRestoreExecutionState() { FlowExecutionImpl flowExecution = (FlowExecutionImpl) factory.createFlowExecution(flowDefinition); LocalAttributeMap<Object> executionAttributes = new LocalAttributeMap<>(); factory.setExecutionAttributes(executionAttributes); FlowExecutionListener listener = new FlowExecutionListener() { };