aboutsummaryrefslogtreecommitdiffstats
path: root/parameter/ParameterMgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'parameter/ParameterMgr.cpp')
-rw-r--r--parameter/ParameterMgr.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/parameter/ParameterMgr.cpp b/parameter/ParameterMgr.cpp
index dc38f95..c1538df 100644
--- a/parameter/ParameterMgr.cpp
+++ b/parameter/ParameterMgr.cpp
@@ -132,6 +132,7 @@ const CParameterMgr::SRemoteCommandParserItem CParameterMgr::gastRemoteCommandPa
{ "dumpDomains", &CParameterMgr::dumpDomainsCommmandProcess, 0, "", "Show all domains and configurations, including applicability conditions" },
{ "createDomain", &CParameterMgr::createDomainCommmandProcess, 1, "<domain>", "Create new configurable domain" },
{ "deleteDomain", &CParameterMgr::deleteDomainCommmandProcess, 1, "<domain>", "Delete configurable domain" },
+ { "deleteAllDomains", &CParameterMgr::deleteAllDomainsCommmandProcess, 0, "", "Delete all configurable domains" },
{ "renameDomain", &CParameterMgr::renameDomainCommmandProcess, 2, "<domain> <new name>", "Rename configurable domain" },
{ "setSequenceAwareness", &CParameterMgr::setSequenceAwarenessCommmandProcess, 1, "<domain> true|false*", "Set configurable domain sequence awareness" },
{ "getSequenceAwareness", &CParameterMgr::getSequenceAwarenessCommmandProcess, 1, "<domain>", "Get configurable domain sequence awareness" },
@@ -872,6 +873,13 @@ CParameterMgr::CCommandHandler::CommandStatus CParameterMgr::deleteDomainCommman
return deleteDomain(remoteCommand.getArgument(0), strResult) ? CCommandHandler::EDone : CCommandHandler::EFailed;
}
+CParameterMgr::CCommandHandler::CommandStatus CParameterMgr::deleteAllDomainsCommmandProcess(const IRemoteCommand& remoteCommand, string& strResult)
+{
+ (void)remoteCommand;
+
+ return deleteAllDomains(strResult) ? CCommandHandler::EDone : CCommandHandler::EFailed;
+}
+
CParameterMgr::CCommandHandler::CommandStatus CParameterMgr::renameDomainCommmandProcess(const IRemoteCommand& remoteCommand, string& strResult)
{
return getConfigurableDomains()->renameDomain(remoteCommand.getArgument(0), remoteCommand.getArgument(1), strResult) ? CCommandHandler::EDone : CCommandHandler::EFailed;
@@ -1447,6 +1455,20 @@ bool CParameterMgr::deleteDomain(const string& strName, string& strError)
return getConfigurableDomains()->deleteDomain(strName, strError);
}
+bool CParameterMgr::deleteAllDomains(string& strError)
+{
+ // Check tuning mode
+ if (!checkTuningModeOn(strError)) {
+
+ return false;
+ }
+
+ // Delegate to configurable domains
+ getConfigurableDomains()->deleteAllDomains();
+
+ return true;
+}
+
bool CParameterMgr::createConfiguration(const string& strDomain, const string& strConfiguration, string& strError)
{
// Check tuning mode