dump_modemlog: move android_property_manager

android_property_manager is moved to its own folder in the root of the
modem folder. This is so that libeomservice proxy has a specific build
target to include.

Test: build, flash, check modem logs in bugreport
Bug: 302435001
Change-Id: Ifc4a0c888717f5c28cf9b642d0b978b495be29d0
This commit is contained in:
kierancyphus 2023-11-10 15:02:57 +08:00 committed by Kieran Cyphus
parent 3ed60cec02
commit 047f0aca49
11 changed files with 296 additions and 116 deletions

View file

@ -0,0 +1,27 @@
#pragma once
#include <string>
#include <string_view>
namespace pixel_modem {
// Used to set boolean parameters to true / false
inline constexpr std::string_view kTruthString = "true";
inline constexpr std::string_view kFalseString = "false";
/**
* @brief Interface for interacting with Android System Properties.
*/
class AndroidPropertyManager {
public:
virtual ~AndroidPropertyManager() = default;
virtual bool GetBoolProperty(const std::string& key, bool default_value) = 0;
virtual std::string GetProperty(const std::string& key,
const std::string& default_value) = 0;
virtual int GetIntProperty(const std::string& key, int default_value) = 0;
virtual bool SetProperty(const std::string& key,
const std::string& value) = 0;
};
} // namespace pixel_modem