@Test(expected = IllegalArgumentException.class) public void loadPhase_missing() throws Exception { Properties p = new Properties(); FlowScript.load(p, "testing", ExecutionPhase.MAIN); }
public static FlowScript load(Properties properties, String flowId) { if (properties == null) { throw new IllegalArgumentException("properties must not be null"); } if (flowId == null) { throw new IllegalArgumentException("flowId must not be null"); } String prefix = getPrefix(flowId); LOG.debug("Loading execution scripts: {}*", prefix); NavigableMap<String, String> flowMap = PropertiesUtil.createPrefixMap(properties, prefix); Set<String> blockerIds = consumeBlockerIds(flowMap, flowId); Set<ExecutionScript.Kind> enables = consumeEnables(flowMap, flowId); Map<ExecutionPhase, List<ExecutionScript>> scripts = consumeScripts(flowMap, flowId); FlowScript script = new FlowScript(flowId, blockerIds, scripts, enables); LOG.trace("Loaded {}*: {}", prefix, script); return script; }
FlowScript { public static FlowScript load(Properties properties, String flowId) { if (properties == null) { throw new IllegalArgumentException("properties must not be null"); } if (flowId == null) { throw new IllegalArgumentException("flowId must not be null"); } String prefix = getPrefix(flowId); LOG.debug("Loading execution scripts: {}*", prefix); NavigableMap<String, String> flowMap = PropertiesUtil.createPrefixMap(properties, prefix); Set<String> blockerIds = consumeBlockerIds(flowMap, flowId); Set<ExecutionScript.Kind> enables = consumeEnables(flowMap, flowId); Map<ExecutionPhase, List<ExecutionScript>> scripts = consumeScripts(flowMap, flowId); FlowScript script = new FlowScript(flowId, blockerIds, scripts, enables); LOG.trace("Loaded {}*: {}", prefix, script); return script; } }
FlowScript { public static FlowScript load(Properties properties, String flowId) { if (properties == null) { throw new IllegalArgumentException("properties must not be null"); } if (flowId == null) { throw new IllegalArgumentException("flowId must not be null"); } String prefix = getPrefix(flowId); LOG.debug("Loading execution scripts: {}*", prefix); NavigableMap<String, String> flowMap = PropertiesUtil.createPrefixMap(properties, prefix); Set<String> blockerIds = consumeBlockerIds(flowMap, flowId); Set<ExecutionScript.Kind> enables = consumeEnables(flowMap, flowId); Map<ExecutionPhase, List<ExecutionScript>> scripts = consumeScripts(flowMap, flowId); FlowScript script = new FlowScript(flowId, blockerIds, scripts, enables); LOG.trace("Loaded {}*: {}", prefix, script); return script; } @Deprecated  FlowScript(
            String id,
            Set<String> blockerIds,
            Map<ExecutionPhase, ? extends Collection<? extends ExecutionScript>> scripts);  FlowScript(
            String id,
            Set<String> blockerIds,
            Map<ExecutionPhase, ? extends Collection<? extends ExecutionScript>> scripts,
            Set<ExecutionScript.Kind> enables); }
FlowScript { public static FlowScript load(Properties properties, String flowId) { if (properties == null) { throw new IllegalArgumentException("properties must not be null"); } if (flowId == null) { throw new IllegalArgumentException("flowId must not be null"); } String prefix = getPrefix(flowId); LOG.debug("Loading execution scripts: {}*", prefix); NavigableMap<String, String> flowMap = PropertiesUtil.createPrefixMap(properties, prefix); Set<String> blockerIds = consumeBlockerIds(flowMap, flowId); Set<ExecutionScript.Kind> enables = consumeEnables(flowMap, flowId); Map<ExecutionPhase, List<ExecutionScript>> scripts = consumeScripts(flowMap, flowId); FlowScript script = new FlowScript(flowId, blockerIds, scripts, enables); LOG.trace("Loaded {}*: {}", prefix, script); return script; } @Deprecated  FlowScript(
            String id,
            Set<String> blockerIds,
            Map<ExecutionPhase, ? extends Collection<? extends ExecutionScript>> scripts);  FlowScript(
            String id,
            Set<String> blockerIds,
            Map<ExecutionPhase, ? extends Collection<? extends ExecutionScript>> scripts,
            Set<ExecutionScript.Kind> enables); String getId(); Set<String> getBlockerIds(); Set<ExecutionScript.Kind> getEnabledScriptKinds(); Map<ExecutionPhase, Set<ExecutionScript>> getScripts(); static FlowScript load(Properties properties, String flowId); static Set<ExecutionScript> load(Properties properties, String flowId, ExecutionPhase phase); static Set<String> extractFlowIds(Properties properties); void storeTo(Properties properties); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString(); }
FlowScript { public static FlowScript load(Properties properties, String flowId) { if (properties == null) { throw new IllegalArgumentException("properties must not be null"); } if (flowId == null) { throw new IllegalArgumentException("flowId must not be null"); } String prefix = getPrefix(flowId); LOG.debug("Loading execution scripts: {}*", prefix); NavigableMap<String, String> flowMap = PropertiesUtil.createPrefixMap(properties, prefix); Set<String> blockerIds = consumeBlockerIds(flowMap, flowId); Set<ExecutionScript.Kind> enables = consumeEnables(flowMap, flowId); Map<ExecutionPhase, List<ExecutionScript>> scripts = consumeScripts(flowMap, flowId); FlowScript script = new FlowScript(flowId, blockerIds, scripts, enables); LOG.trace("Loaded {}*: {}", prefix, script); return script; } @Deprecated  FlowScript(
            String id,
            Set<String> blockerIds,
            Map<ExecutionPhase, ? extends Collection<? extends ExecutionScript>> scripts);  FlowScript(
            String id,
            Set<String> blockerIds,
            Map<ExecutionPhase, ? extends Collection<? extends ExecutionScript>> scripts,
            Set<ExecutionScript.Kind> enables); String getId(); Set<String> getBlockerIds(); Set<ExecutionScript.Kind> getEnabledScriptKinds(); Map<ExecutionPhase, Set<ExecutionScript>> getScripts(); static FlowScript load(Properties properties, String flowId); static Set<ExecutionScript> load(Properties properties, String flowId, ExecutionPhase phase); static Set<String> extractFlowIds(Properties properties); void storeTo(Properties properties); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString(); static final String KEY_FLOW_PREFIX; static final String KEY_ID; static final String KEY_BLOCKERS; static final String KEY_KIND; static final String KEY_CLASS_NAME; static final String KEY_PROFILE; static final String KEY_MODULE; static final String KEY_SUPPORTED_EXTENSIONS; static final String KEY_ENABLED_SCRIPT_KINDS; static final String KEY_ENV_PREFIX; }