Beispiel #1
0
        private static void OnProcess(JobExecution execution, Action<Process> callback)
        {
            int pid = execution.Progress.GetPid();
            Process process = Process.GetProcesses().FirstOrDefault(x => x.Id == pid);

            if (process != null)
                callback(process);
        }
        private new JobExecution Add(JobHeader job)
        {
            JobExecution execution = new JobExecution
            {
                Identifier = Guid.NewGuid(),
                Job = job,
            };

            items.Add(execution);
            return execution;
        }