RestSourceFactory.h (868B)
1 // Copyright (c) Microsoft Corporation. 2 // Licensed under the MIT License. 3 #pragma once 4 #include "ISource.h" 5 #include "SourceFactory.h" 6 #include <string_view> 7 8 namespace AppInstaller::Repository::Rest 9 { 10 using namespace std::string_view_literals; 11 12 // A source where the information is stored on a REST based server. 13 // In addition, the manifest information is also available on the server. 14 // Arg :: Expected to be a API which supports querying functionality. 15 struct RestSourceFactory 16 { 17 // Get the type string for this source. 18 static constexpr std::string_view Type() 19 { 20 using namespace std::string_view_literals; 21 return "Microsoft.Rest"sv; 22 } 23 24 // Creates a source factory for this type. 25 static std::unique_ptr<ISourceFactory> Create(); 26 }; 27 }