Interface.h (1309B)
1 // Copyright (c) Microsoft Corporation. 2 // Licensed under the MIT License. 3 #pragma once 4 #include "Database/Schema/IConfigurationDatabase.h" 5 6 namespace winrt::Microsoft::Management::Configuration::implementation::Database::Schema::V0_1 7 { 8 struct Interface : public IConfigurationDatabase 9 { 10 Interface(std::shared_ptr<AppInstaller::SQLite::SQLiteDynamicStorage> storage); 11 12 const AppInstaller::SQLite::Version& GetSchemaVersion() override; 13 14 // Version 0.1 15 void InitializeDatabase() override; 16 void AddSet(const Configuration::ConfigurationSet& configurationSet) override; 17 void UpdateSet(AppInstaller::SQLite::rowid_t target, const Configuration::ConfigurationSet& configurationSet) override; 18 void RemoveSet(AppInstaller::SQLite::rowid_t target) override; 19 std::vector<ConfigurationSetPtr> GetSets() override; 20 std::optional<AppInstaller::SQLite::rowid_t> GetSetRowId(const GUID& instanceIdentifier) override; 21 22 // Version 0.2 23 bool MigrateFrom(IConfigurationDatabase* current) override; 24 25 // Version 0.3 26 ConfigurationSetPtr GetSet(const GUID& instanceIdentifier) override; 27 28 protected: 29 std::shared_ptr<AppInstaller::SQLite::SQLiteDynamicStorage> m_storage; 30 }; 31 }