Exemple #1
0
        public SubTask getSubTask(int id)
        {
            SubTask serviceSubTask = new SubTask();

            if (System.Threading.Monitor.TryEnter(obj3, 10000))
            {
                try
                {
                    serviceSubTask.Id          = id;
                    serviceSubTask.TaskId      = SubTaskControl.getSubtask(id).taskId;
                    serviceSubTask.Status      = SubTaskControl.getSubtask(id).status;
                    serviceSubTask.Description = SubTaskControl.getSubtask(id).description;
                }
                catch (NullReferenceException)
                {
                }
                finally
                {
                    System.Threading.Monitor.Exit(obj3);
                }
            }
            return(serviceSubTask);
        }
        public SubTask getSubTask(int id)
        {
            SubTask serviceSubTask = new SubTask();
            if (System.Threading.Monitor.TryEnter(obj3, 10000))
            {
                try
                {
                    serviceSubTask.Id = id;
                    serviceSubTask.TaskId = SubTaskControl.getSubtask(id).taskId;
                    serviceSubTask.Status = SubTaskControl.getSubtask(id).status;
                    serviceSubTask.Description = SubTaskControl.getSubtask(id).description;
                }
                catch (NullReferenceException)
                {

                }
                finally
                {
                    System.Threading.Monitor.Exit(obj3);
                }
            }
            return serviceSubTask;
        }
Exemple #3
0
        public List <SubTask> getSubTasks()
        {
            List <SubTask> subTsk = new List <SubTask>();

            if (System.Threading.Monitor.TryEnter(obj4, 10000))
            {
                try
                {
                    List <HealthCareModel.Object_Models.SubTask> returnList = SubTaskControl.getSubtasks();

                    if (returnList.Count != 0)
                    {
                        foreach (HealthCareModel.Object_Models.SubTask subTskHost in returnList)
                        {
                            SubTask serviceSubTask = new SubTask();

                            serviceSubTask.Id          = subTskHost.id;
                            serviceSubTask.TaskId      = subTskHost.taskId;
                            serviceSubTask.Status      = subTskHost.status;
                            serviceSubTask.Description = subTskHost.description;

                            subTsk.Add(serviceSubTask);
                        }
                    }
                }
                catch (NullReferenceException)
                {
                }
                finally
                {
                    System.Threading.Monitor.Exit(obj4);
                }
            }

            return(subTsk);
        }
        public List<SubTask> getSubTasks()
        {
            List<SubTask> subTsk = new List<SubTask>();

            if (System.Threading.Monitor.TryEnter(obj4, 10000))
            {
                try
                {

                    List<HealthCareModel.Object_Models.SubTask> returnList = SubTaskControl.getSubtasks();

                    if (returnList.Count != 0)
                    {
                        foreach (HealthCareModel.Object_Models.SubTask subTskHost in returnList)
                        {
                            SubTask serviceSubTask = new SubTask();

                            serviceSubTask.Id = subTskHost.id;
                            serviceSubTask.TaskId = subTskHost.taskId;
                            serviceSubTask.Status = subTskHost.status;
                            serviceSubTask.Description = subTskHost.description;

                            subTsk.Add(serviceSubTask);
                        }
                    }
                }
                catch (NullReferenceException)
                {
                }
                finally
                {
                    System.Threading.Monitor.Exit(obj4);
                }
            }

            return subTsk;
        }