blob: 5ffd060cf73cc6b3692265bbff9c22d90783075a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#include <string>
#include <optional>
#include <unordered_map>
namespace katja
{
class package
{
std::string m_name;
std::string m_version;
std::string m_architecture;
std::string m_tag;
public:
explicit package(const std::string& name, const std::string& version,
const std::string& architecture, const std::string& tag);
const std::string& name() const noexcept;
const std::string& version() const noexcept;
const std::string& architecture() const noexcept;
const std::string& tag() const noexcept;
static std::optional<package> parse(const std::string& full_name) noexcept;
};
std::unordered_map<std::string, package> read_package_database();
}
|