aboutsummaryrefslogtreecommitdiff
path: root/tools/aconfig/aconfig_storage_file/include/aconfig_storage/aconfig_storage_file.hpp
blob: 5044a4dbfc302f2b4cd57b1048cef891a8a5e51c (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
28
29
30
31
#pragma once

#include <vector>
#include <string>
#include <android-base/result.h>

namespace aconfig_storage {

/// Flag value and info summary for a flag
struct FlagValueAndInfoSummary {
  std::string package_name;
  std::string flag_name;
  std::string flag_value;
  std::string value_type;
  bool is_readwrite;
  bool has_server_override;
  bool has_local_override;
};

/// List all flag values with their flag info
/// \input package_map: package map file
/// \input flag_map: flag map file
/// \input flag_val: flag value file
/// \input flag_info: flag info file
android::base::Result<std::vector<FlagValueAndInfoSummary>> list_flags_with_info(
    const std::string& package_map,
    const std::string& flag_map,
    const std::string& flag_val,
    const std::string& flag_info);

}// namespace aconfig_storage