Пример #1
0
        /// <summary>
        /// Parsed einen REST-Response in ein Model.
        /// </summary>
        /// <param name="jobResponse">Das REST-Modell für einen Job</param>
        /// <returns>Ein Job-Objekt</returns>
        public static Job Parse(JobDetailResponse jobResponse)
        {
            var job = new Job(jobResponse.JobId, jobResponse.StartTime, jobResponse.Active);

            job.EndTime = jobResponse.EndTime;
            job.Creator = jobResponse.Creator;

            foreach (var jobTask in jobResponse.JobTasks)
            {
                job.JobTasks.Add(JobTask.Parse(jobTask));
            }

            return job;
        }
 public JobListElementView(Task t, Job j, NavigateToTaskJobDelegate navigateTo)
 {
     Task = t;
     Job = j;
     navigateToTaskJob = navigateTo;
 }