#include <project_plan.h>

Public Member Functions | |
| std::string | Serialize () const |
| absl::Status | SaveToFile (const std::string &path) const |
| absl::Status | SaveToFile (const std::string &path, const std::string &expected_source) const |
| absl::Status | ValidateIds () const |
| std::string | NewMilestoneId () const |
| std::string | NewStepId () const |
| std::string | NewItemId () const |
| std::string | NewDecisionId () const |
| absl::Status | RenameStep (std::string_view id, std::string new_id) |
| absl::Status | RenameItem (std::string_view id, std::string new_id) |
| int | FindStep (std::string_view id) const |
| std::vector< const PlanRouteItem * > | ItemsAtStep (std::string_view step) const |
| std::vector< const PlanDecision * > | OpenDecisions () const |
| const PlanMilestone * | CurrentMilestone (std::string_view today) const |
Static Public Member Functions | |
| static ProjectPlan | CreateEmpty (std::string title) |
| static absl::StatusOr< ProjectPlan > | Parse (std::string_view text) |
| static absl::StatusOr< ProjectPlan > | LoadFromFile (const std::string &path, std::string *source=nullptr) |
| static absl::Status | CreateAndLink (project::YazeProject *project, const std::string &path) |
| static absl::Status | PublishSource (const std::string &path, const std::string &expected_source, const std::string &text) |
Public Attributes | |
| std::string | title |
| std::string | about |
| PlanGoal | goal |
| std::vector< PlanMilestone > | milestones |
| std::vector< PlanRouteStep > | route_steps |
| std::vector< PlanRouteItem > | route_items |
| PlanJson | route_extra = PlanJson::object() |
| std::vector< PlanDecision > | decisions |
| std::vector< PlanReference > | references |
| PlanJson | extra = PlanJson::object() |
Definition at line 110 of file project_plan.h.
|
static |
|
static |
Definition at line 446 of file project_plan.cc.
References about, decisions, extra, goal, yaze::core::kProjectPlanSchema, milestones, references, RETURN_IF_ERROR, title, and ValidateIds().
Referenced by yaze::core::AdoptPlanAgentOnlyChanges(), yaze::core::ApplyPlanAgentUpdateToFile(), LoadFromFile(), and PublishSource().

|
static |
Definition at line 484 of file project_plan.cc.
References ASSIGN_OR_RETURN, and Parse().
Referenced by yaze::core::ApplyPlanAgentUpdateToFile(), CreateAndLink(), yaze::cli::handlers::PlanReadCommandHandler::Execute(), PublishSource(), yaze::editor::PlanningEditor::Reload(), and yaze::editor::PlanningEditor::Save().

|
static |
Definition at line 499 of file project_plan.cc.
References yaze::core::AcquireSourceArtifactPublicationLock(), ASSIGN_OR_RETURN, yaze::core::ComputeSourceArtifactSha256(), CreateEmpty(), yaze::project::PlanningSettings::file, yaze::project::YazeProject::filepath, LoadFromFile(), yaze::project::YazeProject::name, yaze::project::YazeProject::planning, yaze::core::PublishSourceArtifacts(), and RETURN_IF_ERROR.
Referenced by yaze::editor::PlanningEditor::DrawNoPlan().
| std::string yaze::core::ProjectPlan::Serialize | ( | ) | const |
Definition at line 555 of file project_plan.cc.
References about, decisions, yaze::core::PlanGoal::detail, yaze::core::PlanGoal::due, yaze::core::PlanGoal::extra, extra, goal, yaze::core::kProjectPlanSchema, milestones, references, route_extra, route_items, route_steps, yaze::core::PlanGoal::title, and title.
Referenced by yaze::core::ApplyPlanAgentUpdateToFile(), SaveToFile(), and SaveToFile().
| absl::Status yaze::core::ProjectPlan::SaveToFile | ( | const std::string & | path | ) | const |
Definition at line 662 of file project_plan.cc.
References RETURN_IF_ERROR, Serialize(), ValidateIds(), and yaze::project::WriteProjectFileAtomically().

| absl::Status yaze::core::ProjectPlan::SaveToFile | ( | const std::string & | path, |
| const std::string & | expected_source ) const |
Definition at line 667 of file project_plan.cc.
References PublishSource(), RETURN_IF_ERROR, Serialize(), and ValidateIds().

|
static |
Definition at line 673 of file project_plan.cc.
References yaze::core::AcquireSourceArtifactPublicationLock(), ASSIGN_OR_RETURN, yaze::core::ComputeSourceArtifactSha256(), LoadFromFile(), Parse(), yaze::core::PublishSourceArtifacts(), RETURN_IF_ERROR, and yaze::project::WriteProjectFileAtomically().
Referenced by yaze::core::ApplyPlanAgentUpdateToFile(), and SaveToFile().
| absl::Status yaze::core::ProjectPlan::ValidateIds | ( | ) | const |
Definition at line 692 of file project_plan.cc.
References decisions, milestones, RETURN_IF_ERROR, route_items, and route_steps.
Referenced by Parse(), RenameItem(), RenameStep(), SaveToFile(), and SaveToFile().
| std::string yaze::core::ProjectPlan::NewMilestoneId | ( | ) | const |
Definition at line 699 of file project_plan.cc.
References milestones.
| std::string yaze::core::ProjectPlan::NewStepId | ( | ) | const |
Definition at line 703 of file project_plan.cc.
References decisions, yaze::core::PlanTarget::Parse(), route_items, and route_steps.

| std::string yaze::core::ProjectPlan::NewItemId | ( | ) | const |
Definition at line 730 of file project_plan.cc.
References decisions, yaze::core::PlanTarget::Parse(), route_items, and route_steps.

| std::string yaze::core::ProjectPlan::NewDecisionId | ( | ) | const |
Definition at line 751 of file project_plan.cc.
References decisions, yaze::core::PlanTarget::Parse(), and route_steps.

| absl::Status yaze::core::ProjectPlan::RenameStep | ( | std::string_view | id, |
| std::string | new_id ) |
Definition at line 772 of file project_plan.cc.
References decisions, FindStep(), yaze::core::RenamePlanAgentObservation(), RETURN_IF_ERROR, route_items, route_steps, and ValidateIds().

| absl::Status yaze::core::ProjectPlan::RenameItem | ( | std::string_view | id, |
| std::string | new_id ) |
Definition at line 807 of file project_plan.cc.
References decisions, yaze::core::RenamePlanAgentObservation(), RETURN_IF_ERROR, route_items, route_steps, and ValidateIds().

| int yaze::core::ProjectPlan::FindStep | ( | std::string_view | id | ) | const |
| std::vector< const PlanRouteItem * > yaze::core::ProjectPlan::ItemsAtStep | ( | std::string_view | step | ) | const |
Definition at line 844 of file project_plan.cc.
References route_items.
| std::vector< const PlanDecision * > yaze::core::ProjectPlan::OpenDecisions | ( | ) | const |
Definition at line 855 of file project_plan.cc.
References decisions.
| const PlanMilestone * yaze::core::ProjectPlan::CurrentMilestone | ( | std::string_view | today | ) | const |
Definition at line 871 of file project_plan.cc.
References milestones.
| std::string yaze::core::ProjectPlan::title |
Definition at line 152 of file project_plan.h.
Referenced by CreateEmpty(), yaze::cli::handlers::PlanReadCommandHandler::Execute(), Parse(), and Serialize().
| std::string yaze::core::ProjectPlan::about |
Definition at line 153 of file project_plan.h.
Referenced by Parse(), and Serialize().
| PlanGoal yaze::core::ProjectPlan::goal |
Definition at line 154 of file project_plan.h.
Referenced by Parse(), and Serialize().
| std::vector<PlanMilestone> yaze::core::ProjectPlan::milestones |
Definition at line 155 of file project_plan.h.
Referenced by CurrentMilestone(), yaze::cli::handlers::PlanReadCommandHandler::Execute(), NewMilestoneId(), Parse(), yaze::core::anonymous_namespace{project_plan_agent.cc}::PlanHasTarget(), Serialize(), and ValidateIds().
| std::vector<PlanRouteStep> yaze::core::ProjectPlan::route_steps |
Definition at line 156 of file project_plan.h.
Referenced by yaze::cli::handlers::PlanReadCommandHandler::Execute(), FindStep(), NewDecisionId(), NewItemId(), NewStepId(), yaze::core::anonymous_namespace{project_plan_agent.cc}::PlanHasTarget(), yaze::core::anonymous_namespace{project_plan.cc}::ReadRoute(), RenameItem(), RenameStep(), Serialize(), and ValidateIds().
| std::vector<PlanRouteItem> yaze::core::ProjectPlan::route_items |
Definition at line 157 of file project_plan.h.
Referenced by yaze::cli::handlers::PlanReadCommandHandler::Execute(), ItemsAtStep(), NewItemId(), NewStepId(), yaze::core::anonymous_namespace{project_plan_agent.cc}::PlanHasTarget(), yaze::core::anonymous_namespace{project_plan.cc}::ReadRoute(), RenameItem(), RenameStep(), Serialize(), and ValidateIds().
| PlanJson yaze::core::ProjectPlan::route_extra = PlanJson::object() |
Definition at line 158 of file project_plan.h.
Referenced by yaze::core::anonymous_namespace{project_plan.cc}::ReadRoute(), and Serialize().
| std::vector<PlanDecision> yaze::core::ProjectPlan::decisions |
Definition at line 159 of file project_plan.h.
Referenced by yaze::cli::handlers::PlanReadCommandHandler::Execute(), NewDecisionId(), NewItemId(), NewStepId(), OpenDecisions(), Parse(), yaze::core::anonymous_namespace{project_plan_agent.cc}::PlanHasTarget(), RenameItem(), RenameStep(), Serialize(), and ValidateIds().
| std::vector<PlanReference> yaze::core::ProjectPlan::references |
Definition at line 160 of file project_plan.h.
Referenced by Parse(), and Serialize().
| PlanJson yaze::core::ProjectPlan::extra = PlanJson::object() |
Definition at line 161 of file project_plan.h.
Referenced by yaze::core::AdoptPlanAgentOnlyChanges(), yaze::core::ApplyPlanAgentUpdate(), yaze::core::ApplyPlanAgentUpdateToFile(), yaze::core::anonymous_namespace{project_plan_agent.cc}::ExistingSection(), yaze::core::FindPlanAgentStatus(), Parse(), yaze::core::RenamePlanAgentObservation(), and Serialize().