Commit a3f9cd7b authored by Adrien Béraud's avatar Adrien Béraud

api: remove unused methods

Refs #71525

Change-Id: I11b8629fa42e4fbf413dde14493dccd2c4944242
parent 734c1685
......@@ -635,18 +635,6 @@
</arg>
</method>
<method name="getTlsSettings" tp:name-for-bindings="getTlsSettings">
<annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="MapStringString"/>
<arg type="a{ss}" name="details" direction="out">
</arg>
</method>
<method name="setTlsSettings" tp:name-for-bindings="setTlsSettings">
<annotation name="org.qtproject.QtDBus.QtTypeName.In0" value="MapStringString"/>
<arg type="a{ss}" name="details" direction="in">
</arg>
</method>
<method name="validateCertificate" tp:name-for-bindings="validateCertificate">
<arg type="s" name="accountId" direction="in"></arg>
<arg type="s" name="certificatePath" direction="in">
......
......@@ -364,12 +364,6 @@ DBusConfigurationManager::setHookSettings(const std::map<std::string, std::strin
DRing::setHookSettings(settings);
}
auto
DBusConfigurationManager::getTlsSettings() -> decltype(DRing::getTlsSettings())
{
return DRing::getTlsSettings();
}
auto
DBusConfigurationManager::validateCertificate(const std::string& accountId, const std::string& certificate, const std::string& privateKey) -> decltype(DRing::validateCertificate(accountId, certificate, privateKey))
{
......@@ -394,12 +388,6 @@ DBusConfigurationManager::getCertificateDetailsRaw(const std::vector<uint8_t>& c
return DRing::getCertificateDetailsRaw(certificate);
}
void
DBusConfigurationManager::setTlsSettings(const std::map<std::string, std::string>& details)
{
DRing::setTlsSettings(details);
}
auto
DBusConfigurationManager::getIp2IpDetails() -> decltype(DRing::getIp2IpDetails())
{
......
......@@ -117,8 +117,6 @@ class DBusConfigurationManager :
void setAccountsOrder(const std::string& order);
std::map<std::string, std::string> getHookSettings();
void setHookSettings(const std::map<std::string, std::string>& settings);
std::map<std::string, std::string> getTlsSettings();
void setTlsSettings(const std::map<std::string, std::string>& details);
std::map<std::string, std::string> getIp2IpDetails();
std::vector<std::map<std::string, std::string>> getCredentials(const std::string& accountID);
void setCredentials(const std::string& accountID, const std::vector<std::map<std::string, std::string>>& details);
......
......@@ -130,33 +130,6 @@ getTlsDefaultSettings()
};
}
std::map<std::string, std::string>
getTlsSettings()
{
auto account = ring::Manager::instance().getIP2IPAccount();
if (auto sipaccount = static_cast<SIPAccount*>(account.get()))
return sipaccount->getTlsSettings();
RING_ERR("Could not find IP2IP account");
return std::map<std::string, std::string>();
}
void
setTlsSettings(const std::map<std::string, std::string>& details)
{
auto account = ring::Manager::instance().getIP2IPAccount();
if (auto sipaccount = static_cast<SIPAccount*>(account.get())) {
sipaccount->setTlsSettings(details);
ring::Manager::instance().saveConfig();
// FIXME: inefficient api, don't pass details (not as ref nor copy)
// let client requiests them we needed.
ring::emitSignal<ConfigurationSignal::VolatileDetailsChanged>(account->getAccountID(),
details);
}
RING_DBG("No valid account in set TLS settings");
return;
}
std::map<std::string, std::string>
validateCertificate(const std::string&,
const std::string& certificate,
......
......@@ -111,8 +111,6 @@ void setAccountsOrder(const std::string& order);
std::map<std::string, std::string> getHookSettings();
void setHookSettings(const std::map<std::string, std::string>& settings);
std::map<std::string, std::string> getTlsSettings();
void setTlsSettings(const std::map<std::string, std::string>& details);
std::map<std::string, std::string> getIp2IpDetails();
std::vector<std::map<std::string, std::string>> getCredentials(const std::string& accountID);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment