Skip to content
Snippets Groups Projects
Commit 3ed0c63b authored by Adrien Béraud's avatar Adrien Béraud
Browse files

AccountConfig: use std::filesystem::path

Change-Id: I344c6aa24aad4d0763d8b9dedab100467832920f
parent edf9cee1
No related branches found
No related tags found
No related merge requests found
...@@ -147,7 +147,7 @@ public: ...@@ -147,7 +147,7 @@ public:
std::unique_ptr<AccountConfig> buildConfig() const override std::unique_ptr<AccountConfig> buildConfig() const override
{ {
return std::make_unique<JamiAccountConfig>(getAccountID(), idPath_.string()); return std::make_unique<JamiAccountConfig>(getAccountID(), idPath_);
} }
/** /**
......
...@@ -26,7 +26,7 @@ constexpr static const char* DEFAULT_TURN_PWD = "ring"; ...@@ -26,7 +26,7 @@ constexpr static const char* DEFAULT_TURN_PWD = "ring";
constexpr static const char* DEFAULT_TURN_REALM = "ring"; constexpr static const char* DEFAULT_TURN_REALM = "ring";
struct JamiAccountConfig : public SipAccountBaseConfig { struct JamiAccountConfig : public SipAccountBaseConfig {
JamiAccountConfig(const std::string& id = {}, const std::string& path = {}) JamiAccountConfig(const std::string& id = {}, const std::filesystem::path& path = {})
: SipAccountBaseConfig(std::string(ACCOUNT_TYPE_JAMI), id, path) : SipAccountBaseConfig(std::string(ACCOUNT_TYPE_JAMI), id, path)
{ {
// Default values specific to Jami accounts // Default values specific to Jami accounts
......
...@@ -21,7 +21,7 @@ namespace jami { ...@@ -21,7 +21,7 @@ namespace jami {
constexpr static std::string_view ACCOUNT_TYPE_SIP = "SIP"; constexpr static std::string_view ACCOUNT_TYPE_SIP = "SIP";
struct SipAccountConfig : public SipAccountBaseConfig { struct SipAccountConfig : public SipAccountBaseConfig {
SipAccountConfig(const std::string& id = {}, const std::string& path = {}): SipAccountBaseConfig(std::string(ACCOUNT_TYPE_SIP), id, path) {} SipAccountConfig(const std::string& id = {}, const std::filesystem::path& path = {}): SipAccountBaseConfig(std::string(ACCOUNT_TYPE_SIP), id, path) {}
void serialize(YAML::Emitter& out) const override; void serialize(YAML::Emitter& out) const override;
void unserialize(const YAML::Node& node) override; void unserialize(const YAML::Node& node) override;
std::map<std::string, std::string> toMap() const override; std::map<std::string, std::string> toMap() const override;
......
...@@ -24,7 +24,7 @@ constexpr static unsigned MAX_PORT {65536}; ...@@ -24,7 +24,7 @@ constexpr static unsigned MAX_PORT {65536};
constexpr static unsigned HALF_MAX_PORT {MAX_PORT / 2}; constexpr static unsigned HALF_MAX_PORT {MAX_PORT / 2};
struct SipAccountBaseConfig: public AccountConfig { struct SipAccountBaseConfig: public AccountConfig {
SipAccountBaseConfig(const std::string& type, const std::string& id, const std::string& path) SipAccountBaseConfig(const std::string& type, const std::string& id, const std::filesystem::path& path)
: AccountConfig(type, id, path) {} : AccountConfig(type, id, path) {}
void serializeDiff(YAML::Emitter& out, const SipAccountBaseConfig& def) const; void serializeDiff(YAML::Emitter& out, const SipAccountBaseConfig& def) const;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment