/// <summary> /// Method that returns all Tasks /// </summary> /// <returns>Return a list of Tasks</returns> public List <Task> getAllTasks() { List <Task> taskList = TaskConnection.readAllTasks(); foreach (Task _t in taskList) { returnWithoutSpaces(_t); } return(taskList); }
public void OffsetAllIndices(int offset) { Index += offset; if (Connections != null) { for (int i = 0; i < Connections.Length; i++) { Connections[i] = new TaskConnection(Connections[i].OutPin, Connections[i].InNode + offset, Connections[i].InName); } } }
/// <summary> /// Updates a task. /// </summary> /// <param name="code">The code task to update</param> /// <param name="name">The name task to update</param> /// <param name="priorityDate">The priority date task to update</param> /// <param name="description">The description task to update</param> /// <param name="localization">The localization task to update</param> /// <param name="project">The project name task to update</param> /// <returns>Whether if the task has been correctly updated or not</returns> public bool updateTask(String code, String name, DateTime priorityDate, String description, String localization, String project, String team, int importance) { Task newTask = new Task { code = code, name = name, id_team = team, priorityDate = priorityDate, description = description, localization = localization, project = project, priority = importance }; return(TaskConnection.updateTask(newTask)); }
/// <summary> /// Creates a task given it's atributes. /// </summary> /// <param name="code">The code task to create</param> /// <param name="name">The name task to create</param> /// <param name="priorityDate">The priority date task to create</param> /// <param name="description">The description task to create</param> /// <param name="localization">The localization task to create</param> /// <param name="project">The project name task to create</param> /// <author>Pablo A.</author> /// <returns>Whether if the task has been correctly created or not</returns> public bool createTask(String code, String name, DateTime priorityDate, String description, String localization, String project, String team, int importance) { Task newTask = new Task { code = code.Trim(), id_team = team, name = name.Trim(), priorityDate = priorityDate, description = description.Trim(), localization = localization.Trim(), project = project.Trim(), priority = importance, state = (int)TaskState.UNSELECTED }; return(TaskConnection.createTask(newTask)); }
public void readTaskTest() { Assert.Equals(null, TaskConnection.readTask("something")); }
/// <summary> /// Method that deletes a Task if it exists /// </summary> /// <param name="pCode">The code task to search</param> /// <returns>Returns the Task if it has been remove</returns> public Task deleteTask(Task pTask) { return(TaskConnection.deleteTask(pTask)); }
/// <summary> /// Method that returns the Task if it found /// </summary> /// <param name="pCode">The code task to search</param> /// <returns>Returns the Task if it found</returns> public Task readTask(String pCode) { Task tReturn = TaskConnection.readTask(pCode); return(returnWithoutSpaces(tReturn)); }
public NodeTaskData(string task, Connection con, NodeInfo info) { _connection = new TaskConnection(con.Address, con.Port, task); _nodeInfo = info; LastActiveDate = DateTime.Now; }