Examples of FlowDefinitionRegistry


Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

    FlowLocation location2 = new FlowLocation("flow2", "org/springframework/webflow/config/flow.xml", attributes);
    FlowLocation[] flowLocations = new FlowLocation[] { location1, location2 };
    factoryBean.setFlowBuilderServices(TestFlowBuilderServicesFactory.getServices());
    factoryBean.setFlowLocations(flowLocations);
    factoryBean.afterPropertiesSet();
    FlowDefinitionRegistry registry = (FlowDefinitionRegistry) factoryBean.getObject();
    FlowDefinition def = registry.getFlowDefinition("flow1");
    assertNotNull(def);
    assertEquals("flow1", def.getId());
    assertEquals("bar", def.getAttributes().get("foo"));
    assertEquals(new Integer(2), def.getAttributes().getInteger("bar"));
    def = registry.getFlowDefinition("flow2");
    assertNotNull(def);
    assertEquals("flow2", def.getId());
  }
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

    FlowLocation location1 = new FlowLocation(null, "org/springframework/webflow/config/flow.xml", null);
    FlowLocation[] flowLocations = new FlowLocation[] { location1 };
    factoryBean.setFlowBuilderServices(TestFlowBuilderServicesFactory.getServices());
    factoryBean.setFlowLocations(flowLocations);
    factoryBean.afterPropertiesSet();
    FlowDefinitionRegistry registry = (FlowDefinitionRegistry) factoryBean.getObject();
    FlowDefinition def = registry.getFlowDefinition("flow");
    assertNotNull(def);
    assertEquals("flow", def.getId());
    assertTrue(def.getAttributes().isEmpty());
  }
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

    FlowLocation location1 = new FlowLocation(null, "org/springframework/webflow/config/flow.xml", null);
    FlowLocation[] flowLocations = new FlowLocation[] { location1 };
    factoryBean.setFlowLocations(flowLocations);
    factoryBean.setFlowBuilderServices(TestFlowBuilderServicesFactory.getServices());
    factoryBean.afterPropertiesSet();
    FlowDefinitionRegistry registry = (FlowDefinitionRegistry) factoryBean.getObject();
    FlowDefinition def = registry.getFlowDefinition("flow");
    assertNotNull(def);
    assertEquals("flow", def.getId());
    assertTrue(def.getAttributes().isEmpty());
  }
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

    FlowLocation location2 = new FlowLocation("flow2", "org/springframework/webflow/config/flow.xml", attributes);
    FlowLocation[] flowLocations = new FlowLocation[] { location1, location2 };
    factoryBean.setFlowBuilderServices(TestFlowBuilderServicesFactory.getServices());
    factoryBean.setFlowLocations(flowLocations);
    factoryBean.afterPropertiesSet();
    FlowDefinitionRegistry registry = factoryBean.getObject();
    FlowDefinition def = registry.getFlowDefinition("flow1");
    assertNotNull(def);
    assertEquals("flow1", def.getId());
    assertEquals("bar", def.getAttributes().get("foo"));
    assertEquals(new Integer(2), def.getAttributes().getInteger("bar"));
    def = registry.getFlowDefinition("flow2");
    assertNotNull(def);
    assertEquals("flow2", def.getId());
  }
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

    FlowLocation location1 = new FlowLocation(null, "org/springframework/webflow/config/flow.xml", null);
    FlowLocation[] flowLocations = new FlowLocation[] { location1 };
    factoryBean.setFlowBuilderServices(TestFlowBuilderServicesFactory.getServices());
    factoryBean.setFlowLocations(flowLocations);
    factoryBean.afterPropertiesSet();
    FlowDefinitionRegistry registry = factoryBean.getObject();
    FlowDefinition def = registry.getFlowDefinition("flow");
    assertNotNull(def);
    assertEquals("flow", def.getId());
    assertTrue(def.getAttributes().isEmpty());
  }
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

    FlowLocation location1 = new FlowLocation(null, "org/springframework/webflow/config/flow.xml", null);
    FlowLocation[] flowLocations = new FlowLocation[] { location1 };
    factoryBean.setFlowLocations(flowLocations);
    factoryBean.setFlowBuilderServices(TestFlowBuilderServicesFactory.getServices());
    factoryBean.afterPropertiesSet();
    FlowDefinitionRegistry registry = factoryBean.getObject();
    FlowDefinition def = registry.getFlowDefinition("flow");
    assertNotNull(def);
    assertEquals("flow", def.getId());
    assertTrue(def.getAttributes().isEmpty());
  }
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

      {
         if (source instanceof FlowHandlerMapping)
         {
            FlowHandlerMapping mapping = (FlowHandlerMapping) source;
            HashMap<String, Object> result = new HashMap<String, Object>();
            FlowDefinitionRegistry registry = mapping.getFlowRegistry();
            for (String flowId: registry.getFlowDefinitionIds())
            {
               result.put(flowId, registry.getFlowDefinition(flowId));
            }
            return (T)result;
         }
        
        
View Full Code Here

Examples of org.springframework.webflow.definition.registry.FlowDefinitionRegistry

        
         return result;
      }
      catch (NoSuchFlowDefinitionException ex)
      {
         FlowDefinitionRegistry registry = getApplicationContext().getBean(FlowDefinitionRegistry.class);
         String flows = Arrays.asList( registry.getFlowDefinitionIds()).toString();
         NoSuchElementException exception = new NoSuchElementException("Did not find flow '" + ex.getFlowDefinitionId() + "' in " + flows);
         exception.initCause(ex);
         throw exception;
      }
      catch (IllegalArgumentException ex){
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.