Horizon
Loading...
Searching...
No Matches
pool_cache_status.hpp
1#pragma once
2#include "common/common.hpp"
3#include "util/uuid.hpp"
4#include "pool_cache_status.hpp"
5#include "nlohmann/json.hpp"
6#include <list>
7
8namespace horizon {
9using json = nlohmann::json;
10
12public:
13 class Item {
14 public:
15 std::string name;
16 std::string filename_cached;
17 std::string filename_pool;
18 ObjectType type;
19 UUID uuid;
20 UUID pool_uuid;
21 enum class State { CURRENT, OUT_OF_DATE, MISSING_IN_POOL };
22
23 State state;
24 json delta;
25 };
26
27 std::list<Item> items;
28 unsigned int n_total = 0;
29 unsigned int n_current = 0;
30 unsigned int n_missing = 0;
31 unsigned int n_out_of_date = 0;
32 static PoolCacheStatus from_project_pool(class IPool &pool);
33};
34} // namespace horizon
Definition ipool.hpp:15
Definition pool_cache_status.hpp:13
Definition pool_cache_status.hpp:11
This class encapsulates a UUID and allows it to be uses as a value type.
Definition uuid.hpp:16
a class to store JSON values
Definition json.hpp:177
basic_json<> json
default JSON class
Definition json_fwd.hpp:62