40 addContract(
const std::shared_ptr<core::domain::Contract>& contract)
override;
46 std::vector<std::shared_ptr<core::domain::Contract>>
54 std::optional<std::shared_ptr<core::domain::Contract>>
68 const std::shared_ptr<core::domain::Contract>& contract)
override;
75 const std::shared_ptr<core::domain::Contract>& contract)
override;
87 std::vector<std::shared_ptr<core::domain::Contract>>
94 std::vector<std::shared_ptr<core::domain::Contract>>
101 std::vector<std::string>
108 std::vector<std::string>
113 std::unique_ptr<Impl> pimpl_;
Repository port for core::domain::Contract persistence operations.
std::vector< std::string > getPropertyIdsForContract(const std::string &contractId) const override
Retrieve property identifiers linked to a contract.
std::vector< std::string > getActorIdsForContract(const std::string &contractId) const override
Retrieve actor identifiers linked to a contract.
std::vector< std::shared_ptr< core::domain::Contract > > getContractsForActor(const std::string &actorId) const override
Retrieve contracts associated with a given actor.
void removeContract(const std::string &id) override
Remove a contract by identifier.
void updateContract(const std::shared_ptr< core::domain::Contract > &contract) override
Update an existing contract.
std::vector< std::shared_ptr< core::domain::Contract > > getContracts() const override
Retrieve all contracts.
void upsertContract(const std::shared_ptr< core::domain::Contract > &contract) override
Insert or update a contract.
std::vector< std::shared_ptr< core::domain::Contract > > getContractsForProperty(const std::string &propertyId) const override
Retrieve contracts associated with a given property.
void addContract(const std::shared_ptr< core::domain::Contract > &contract) override
Insert a new contract.
std::optional< std::shared_ptr< core::domain::Contract > > getContractById(const std::string &id) const override
Retrieve a contract by identifier.
~SqliteContractRepository() override
Destroy the repository.
SqliteContractRepository(const std::string &dbPath)
Create a contract repository for the database at the given path.
void clearContracts() override
Remove all contracts.