Пример #1
0
        /// <summary>
        /// Runs the job specified by the definition
        /// </summary>
        /// <param name="job">The definition of the job to run</param>
        private void _runJob(IJobDefinition job)
        {
            PipelineDefinition d = job.GetAlgorithms();

            Pipeline.Pipeline pipeline = _currentArgs.PipelineFactory.CreatePipeline(d);
            foreach (JobInput input in job.GetInputs())
            {
                if (_handleNextInput(pipeline, input) == false)
                {
                    return;
                }
            }

            var results = _currentArgs.Persister.Load(_ticket.JobID);

            _ticket.Result = new JobResult(results);
            _ticket.State  = JobState.Complete;
            _ticket.OnJobCompleted();
        }