| | |
| | | |
| | | // —— 基本属性 —— // |
| | | const std::string& id() const noexcept { return m_cjId; } |
| | | void setId(std::string& id); |
| | | CJState state() const noexcept { return m_state; } |
| | | uint8_t priority() const noexcept { return m_priority; } |
| | | void setPriority(uint8_t p) noexcept { m_priority = p; } |
| | |
| | | bool containsPJ(const std::string& pjId) const; |
| | | const std::vector<std::string>& pjIds() const noexcept { return m_pjIds; } |
| | | bool setPJs(const std::vector<CProcessJob*>& pjs); |
| | | bool removePjPointer(const std::string& id); |
| | | bool addPjPointer(CProcessJob* pj); |
| | | void clearPJs() { m_pjIds.clear(); } |
| | | const std::vector<CProcessJob*>& getPjs() { return m_pjs; }; |
| | | |
| | |
| | | const std::function<bool(const std::string&)>& getPjExistsFn, |
| | | const std::function<bool(const std::string&)>& canJoinFn |
| | | ); |
| | | const std::vector<CControlJob::ValidationIssue>& CControlJob::issues(); |
| | | const std::vector<ValidationIssue>& CControlJob::issues(); |
| | | void clearIssues(); |
| | | |
| | | // —— S14F9 → S14F10 的“应用结果”模型 —— // |
| | | struct CreateRequest { |
| | |
| | | bool pause(); // Executing -> Paused |
| | | bool resume(); // Paused -> Executing |
| | | bool complete(); // Executing/Paused -> Completed |
| | | bool abort(); // 非终态 -> Aborted |
| | | bool abort(std::string reason); // 非终态 -> Aborted |
| | | bool fail(std::string reason); // 任意 -> Failed |
| | | |
| | | const std::string& failReason() const noexcept { return m_failReason; } |