part of '../persistence.dart'; /// Repository contract for project profile records. abstract interface class ProjectRepository { /// Return the project with [projectId] in [ownerId], or null when absent. Future> findById({ required core.OwnerId ownerId, required String projectId, }); /// Return owner-scoped projects, optionally including archived profiles. Future>> findByOwner({ required core.OwnerId ownerId, bool includeArchived = false, core.PageRequest page = const core.PageRequest(), }); /// Insert [project] for [ownerId] and return the assigned revision. Future> insert({ required core.OwnerId ownerId, required core.ProjectProfile project, }); /// Save [project] if [expectedRevision] still matches the stored record. Future> save({ required core.OwnerId ownerId, required core.ProjectProfile project, required core.Revision expectedRevision, }); /// Archive [projectId] without deleting task history. Future> archive({ required core.OwnerId ownerId, required String projectId, required core.Revision expectedRevision, required DateTime archivedAtUtc, }); }