Search in sources :

Example 21 with FlowScript

use of org.ow2.proactive.scheduler.common.task.flow.FlowScript in project scheduling by ow2-proactive.

the class TagTest method createLoopTask.

private InternalScriptTask createLoopTask(String name, String scriptContent, InternalTask[] dependences, String targetName, boolean block) throws InvalidScriptException {
    FlowBlock fb = null;
    if (block) {
        fb = FlowBlock.END;
    }
    InternalScriptTask result = createTask(name, dependences, fb, targetName);
    FlowScript loop = FlowScript.createLoopFlowScript(scriptContent, targetName);
    result.setFlowScript(loop);
    return result;
}
Also used : FlowBlock(org.ow2.proactive.scheduler.common.task.flow.FlowBlock) InternalScriptTask(org.ow2.proactive.scheduler.task.internal.InternalScriptTask) FlowScript(org.ow2.proactive.scheduler.common.task.flow.FlowScript)

Aggregations

FlowScript (org.ow2.proactive.scheduler.common.task.flow.FlowScript)18 SimpleScript (org.ow2.proactive.scripting.SimpleScript)11 Test (org.junit.Test)9 Script (org.ow2.proactive.scripting.Script)9 TaskFlowJob (org.ow2.proactive.scheduler.common.job.TaskFlowJob)4 JavaTask (org.ow2.proactive.scheduler.common.task.JavaTask)4 InternalScriptTask (org.ow2.proactive.scheduler.task.internal.InternalScriptTask)2 InternalTask (org.ow2.proactive.scheduler.task.internal.InternalTask)2 EmptyExecutable (functionaltests.executables.EmptyExecutable)1 InvalidPatternException (it.sauronsoftware.cron4j.InvalidPatternException)1 Predictor (it.sauronsoftware.cron4j.Predictor)1 FileNotFoundException (java.io.FileNotFoundException)1 Date (java.util.Date)1 XMLStreamException (javax.xml.stream.XMLStreamException)1 VerifierConfigurationException (org.iso_relax.verifier.VerifierConfigurationException)1 JobCreationException (org.ow2.proactive.scheduler.common.exception.JobCreationException)1 JobValidationException (org.ow2.proactive.scheduler.common.exception.JobValidationException)1 JobId (org.ow2.proactive.scheduler.common.job.JobId)1 JobResult (org.ow2.proactive.scheduler.common.job.JobResult)1 ForkEnvironment (org.ow2.proactive.scheduler.common.task.ForkEnvironment)1