public JobRuntime( IDataFlowConnection connection, DataContractOptions dtoOptions, Japi.Job job, IJobResultReader jobResultReader) { if (connection == null) throw new ArgumentNullException("connection"); if (dtoOptions == null) throw new ArgumentNullException("dtoOptions"); if (job == null) throw new ArgumentNullException("job"); if (jobResultReader == null) throw new ArgumentNullException("job"); this.connection = connection; this.dtoOptions = dtoOptions; this.job = job; this.jobResultReader = jobResultReader; executionSequence = new JobExecutionSequence(this); JobStateIndeterminable(); }
public static TaskWithCounter Create(Japi.Task task) { return new TaskWithCounter(task, task.Dependencies.Count); }
public static TaskWithCounter Update(TaskWithCounter currentTask, Japi.Task selectedTask) { if (currentTask.Task.Dependencies.Contains(selectedTask)) { return new TaskWithCounter(currentTask.Task, currentTask.Dependencies - 1); } return new TaskWithCounter(currentTask.Task, currentTask.Dependencies); }
public TaskWithCounter(Japi.Task task, int dependencies) { Task = task; Dependencies = dependencies; }