void Channel::addTasks( const uint32_t tasks ) { Window* window = getWindow(); EQASSERT( window ); setTasks( getTasks() | tasks ); window->addTasks( tasks ); }
void Pipe::addTasks( const uint32_t tasks ) { Node* node = getNode(); EQASSERT( node ); setTasks( getTasks() | tasks ); node->addTasks( tasks ); }
void Window::addTasks( const uint32_t tasks ) { Pipe* pipe = getPipe(); EQASSERT( pipe ); setTasks( getTasks() | tasks ); pipe->addTasks( tasks ); }
void Worker::childChange(const string &path) { if (path == m_assign_dir) { getTasks(); } }
void TaskMap<CostInfo>::setPriorityTasks(Vec2 pos) { for (Task* t : getTasks(pos)) priorityTasks.insert(t); }
QString TAEval::serveRequest(QString request, QString data) { //Then find the request here and delegate the data to the SQL to query the required info. if(request.compare("loginRequest") == 0){ qDebug() << "Login Request being processed" << endl; QString l = accessControl.logIn(data); if(l.contains("Instructor")) { return QString("Instructor"); } if(l.contains("TA")) { return QString("TA"); } if(l.contains("loggedin")) { return QString("loggedin"); } else return QString("false"); } else if (request.compare("semesterRequest") == 0) { qDebug() << "Semester Request being processed" << endl; StringList *semesters; if(getSemesters(data, semesters)) { QString result = listToString(*semesters); delete semesters; return result.isEmpty() ? "false" : result; } } else if (request.compare("coursesRequest") == 0) { qDebug() << "Courses Request being processed" << endl; QStringList info = data.split("|"); qDebug() << info.at(0) + " " + info.at(1) << endl; CourseList* c; if(getCourses(info.at(0), c, info.at(0), info.at(1))) { QString stringOfCourses = Course::listToString(*c); qDebug() << stringOfCourses << endl; delete c; return (stringOfCourses.isEmpty()) ? "false" : stringOfCourses; } } else if (request.compare("tasRequest") == 0) { qDebug() << "TAs Request being processed" << endl; QStringList info = data.split("|"); qDebug() << "Inst here is: " + info.at(0) + " and " + info.at(1) << endl; TAList* t; if(getTAs(info.at(0), info.at(1), t)) { QString stringOfTAs = TA::listToString(*t);delete t; qDebug() << stringOfTAs << endl; return (stringOfTAs.isEmpty()) ? "false" : stringOfTAs; } } else if (request.compare("taskRequest") == 0) { qDebug() << "Task Request being processed" << endl; QStringList info = data.split("|"); qDebug() << "Inst here is: " + info.at(0) + " and " + info.at(1) << " and " << info.at(2) << endl; TaskList* taskList; if(getTasks(info.at(0), info.at(1), info.at(2), taskList)) { QString stringOfTask = Task::listToString(*taskList); delete taskList; qDebug() << stringOfTask << endl; return (stringOfTask.isEmpty()) ? "false" : stringOfTask; } else return "false"; } else if (request.compare("taskCreateRequest") == 0) { qDebug() << "Create Task Request being processed" << endl; QStringList info = data.split("|"); qDebug() << "Inst here is: " + info.at(0) + " and " + info.at(1) << " and " << info.at(2) + " and " + info.at(3) << " and " << info.at(4) << + " and " + info.at(5) << endl; QStringList begDateList = info.at(4).split("-"); QStringList dueDateList = info.at(5).split("-"); QDate begDate(begDateList.at(0).toInt(), begDateList.at(1).toInt(), begDateList.at(2).toInt()); QDate dueDate(dueDateList.at(0).toInt(), dueDateList.at(1).toInt(), dueDateList.at(2).toInt()); return createTask(info.at(0), info.at(1), info.at(2), info.at(3), begDate, dueDate) ? "true" : "false"; } else if (request.compare("taskEditRequest") == 0) { qDebug() << "Edit Task Request being processed" << endl; QStringList info = data.split("|"); qDebug() << "Inst here is: " + info.at(0) + " and " + info.at(1) + " and " + info.at(2) + " and " + info.at(3) + "and " + info.at(4) << endl; QStringList begDateList = info.at(2).split("-"); QStringList dueDateList = info.at(3).split("-"); QDate begDate(begDateList.at(0).toInt(), begDateList.at(1).toInt(), begDateList.at(2).toInt()); QDate dueDate(dueDateList.at(0).toInt(), dueDateList.at(1).toInt(), dueDateList.at(2).toInt()); return editTask(info.at(0), info.at(1), begDate, dueDate, QString(info.at(4))) ? "true" : "false"; } else if (request.compare("taskDeleteRequest") == 0){ qDebug() << "DELETE Task Request being processed" << endl; QStringList info = data.split("|"); qDebug() << "Inst here is: " + info.at(0) + " and " + info.at(1) << endl; return deleteTask(info.at(0), QString(info.at(1))) ? "true" : "false"; } else if (request.compare("editEvalRequest") == 0){ qDebug() << "Edit Evail Request being processed" << endl; QStringList info = data.split("|"); return enterEvaluation(info.at(0), info.at(1).toInt(), info.at(2), info.at(3).toInt()) ? "true" : "false"; } else if (request.compare("logOutRequest") == 0){ qDebug() << "LogOut Request being processed" << endl; QStringList info = data.split("|"); qDebug() << "Inst here is: " + info.at(0) << endl; return accessControl.logOut(info.at(0)) ? "true" : "false"; } qDebug() << "Request Failed" << endl; return "false"; }