diff options
author | JackLivio <jack@livio.io> | 2019-01-30 14:11:12 -0500 |
---|---|---|
committer | JackLivio <jack@livio.io> | 2019-01-30 14:11:12 -0500 |
commit | 59e638c2ae6722b07e70423eff9d3eb44c9581bb (patch) | |
tree | b83d53c524baf51b94c49c15800f840a29e13cc1 /src/components/application_manager/rpc_plugins | |
parent | 2f5fe1b89dc6d15fb9bb2e42083db23edf3de276 (diff) | |
parent | c0bc15dbfcf78eaa3bcecb34b28fe98a5c9a1757 (diff) | |
download | sdl_core-59e638c2ae6722b07e70423eff9d3eb44c9581bb.tar.gz |
Merge remote-tracking branch 'origin/feature/base_app_services_implementation' into feature/app_service_policies
Diffstat (limited to 'src/components/application_manager/rpc_plugins')
2 files changed, 5 insertions, 12 deletions
diff --git a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_publish_app_service_request.cc b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_publish_app_service_request.cc index 835762f78a..1e235c1282 100644 --- a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_publish_app_service_request.cc +++ b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/hmi/as_publish_app_service_request.cc @@ -80,17 +80,14 @@ void ASPublishAppServiceRequest::Run() { LOG4CXX_AUTO_TRACE(logger_); smart_objects::SmartObject response_params = smart_objects::SmartObject(smart_objects::SmartType_Map); - smart_objects::SmartObject service_record = - smart_objects::SmartObject(smart_objects::SmartType_Map); smart_objects::SmartObject manifest = (*message_)[strings::msg_params][strings::app_service_manifest]; if (!ValidateManifest(manifest)) { return; } - service_record[strings::service_manifest] = manifest; - service_record[strings::service_id] = "This is a service ID"; - service_record[strings::service_published] = true; - service_record[strings::service_active] = true; + smart_objects::SmartObject service_record = + application_manager_.GetAppServiceManager().PublishAppService(manifest); + response_params[strings::app_service_record] = service_record; // TODO: Add AppServiceRecord to response SendResponse(true, diff --git a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/publish_app_service_request.cc b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/publish_app_service_request.cc index c19cd22859..f975cb0543 100644 --- a/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/publish_app_service_request.cc +++ b/src/components/application_manager/rpc_plugins/app_service_rpc_plugin/src/commands/mobile/publish_app_service_request.cc @@ -84,17 +84,13 @@ void PublishAppServiceRequest::Run() { smart_objects::SmartObject response_params = smart_objects::SmartObject(smart_objects::SmartType_Map); - smart_objects::SmartObject service_record = - smart_objects::SmartObject(smart_objects::SmartType_Map); smart_objects::SmartObject manifest = (*message_)[strings::msg_params][strings::app_service_manifest]; if (!ValidateManifest(manifest)) { return; } - service_record[strings::service_manifest] = manifest; - service_record[strings::service_id] = "This is a service ID"; - service_record[strings::service_published] = true; - service_record[strings::service_active] = true; + smart_objects::SmartObject service_record = + application_manager_.GetAppServiceManager().PublishAppService(manifest); std::string requested_service_name = (*message_)[strings::msg_params][strings::app_service_manifest] |