summaryrefslogtreecommitdiff
path: root/src/components/application_manager/src/commands/command_request_impl.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/application_manager/src/commands/command_request_impl.cc')
-rw-r--r--src/components/application_manager/src/commands/command_request_impl.cc26
1 files changed, 7 insertions, 19 deletions
diff --git a/src/components/application_manager/src/commands/command_request_impl.cc b/src/components/application_manager/src/commands/command_request_impl.cc
index 09aa4169e5..a2e4e44ec3 100644
--- a/src/components/application_manager/src/commands/command_request_impl.cc
+++ b/src/components/application_manager/src/commands/command_request_impl.cc
@@ -306,25 +306,6 @@ void CommandRequestImpl::SendResponse(
application_manager_.ManageMobileCommand(result, ORIGIN_SDL);
}
-bool CommandRequestImpl::CheckSyntax(const std::string& str,
- bool allow_empty_line) {
- if (std::string::npos != str.find_first_of("\t\n")) {
- LOG4CXX_ERROR(logger_, "CheckSyntax failed! :" << str);
- return false;
- }
- if (std::string::npos != str.find("\\n") ||
- std::string::npos != str.find("\\t")) {
- LOG4CXX_ERROR(logger_, "CheckSyntax failed! :" << str);
- return false;
- }
- if (!allow_empty_line) {
- if ((std::string::npos == str.find_first_not_of(' '))) {
- return false;
- }
- }
- return true;
-}
-
smart_objects::SmartObject CreateUnsupportedResourceResponse(
const hmi_apis::FunctionID::eType function_id,
const uint32_t hmi_correlation_id,
@@ -578,6 +559,13 @@ mobile_apis::Result::eType CommandRequestImpl::GetMobileResultCode(
return mobile_result;
}
+bool CommandRequestImpl::CheckHMIInterfaceAvailability(
+ const HmiInterfaces::InterfaceID interface) const {
+ const HmiInterfaces::InterfaceState interface_state =
+ application_manager_.hmi_interfaces().GetInterfaceState(interface);
+ return HmiInterfaces::InterfaceState::STATE_NOT_AVAILABLE != interface_state;
+}
+
bool CommandRequestImpl::CheckAllowedParameters() {
LOG4CXX_AUTO_TRACE(logger_);