summaryrefslogtreecommitdiff
path: root/src/components/application_manager/include/application_manager/application_manager_impl.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/application_manager/include/application_manager/application_manager_impl.h')
-rw-r--r--src/components/application_manager/include/application_manager/application_manager_impl.h41
1 files changed, 37 insertions, 4 deletions
diff --git a/src/components/application_manager/include/application_manager/application_manager_impl.h b/src/components/application_manager/include/application_manager/application_manager_impl.h
index 12f2310d36..27be913cd5 100644
--- a/src/components/application_manager/include/application_manager/application_manager_impl.h
+++ b/src/components/application_manager/include/application_manager/application_manager_impl.h
@@ -117,6 +117,14 @@ struct CommandParametersPermissions;
typedef std::map<std::string, hmi_apis::Common_TransportType::eType>
DeviceTypes;
+struct AppIconInfo {
+ std::string endpoint;
+ bool pending_request;
+ AppIconInfo();
+ AppIconInfo(std::string ws_endpoint, bool pending)
+ : endpoint(ws_endpoint), pending_request(pending) {}
+};
+
CREATE_LOGGERPTR_GLOBAL(logger_, "ApplicationManager")
typedef std::shared_ptr<timer::Timer> TimerSPtr;
@@ -156,6 +164,7 @@ class ApplicationManagerImpl
bool Stop() OVERRIDE;
DataAccessor<ApplicationSet> applications() const OVERRIDE;
+ DataAccessor<AppsWaitRegistrationSet> pending_applications() const OVERRIDE;
ApplicationSharedPtr application(uint32_t app_id) const OVERRIDE;
ApplicationSharedPtr active_application() const OVERRIDE;
@@ -164,6 +173,10 @@ class ApplicationManagerImpl
uint32_t hmi_app_id) const OVERRIDE;
ApplicationSharedPtr application_by_policy_id(
const std::string& policy_app_id) const OVERRIDE;
+ ApplicationSharedPtr application_by_name(
+ const std::string& app_name) const OVERRIDE;
+ ApplicationSharedPtr pending_application_by_policy_id(
+ const std::string& policy_app_id) const OVERRIDE;
std::vector<ApplicationSharedPtr> applications_by_button(
uint32_t button) OVERRIDE;
@@ -194,6 +207,9 @@ class ApplicationManagerImpl
void SendDriverDistractionState(ApplicationSharedPtr application);
+ void SendGetIconUrlNotifications(const uint32_t connection_key,
+ ApplicationSharedPtr application);
+
ApplicationSharedPtr application(
const std::string& device_id,
const std::string& policy_app_id) const OVERRIDE;
@@ -365,6 +381,8 @@ class ApplicationManagerImpl
void ConnectToDevice(const std::string& device_mac) OVERRIDE;
void OnHMIStartedCooperation() OVERRIDE;
+ void DisconnectCloudApp(ApplicationSharedPtr app) OVERRIDE;
+
void RefreshCloudAppInformation() OVERRIDE;
void CreatePendingApplication(
@@ -372,6 +390,14 @@ class ApplicationManagerImpl
const transport_manager::DeviceInfo& device_info,
connection_handler::DeviceHandle device_id);
+ void SetPendingApplicationState(
+ const transport_manager::ConnectionUID connection_id,
+ const transport_manager::DeviceInfo& device_info);
+
+ std::string PolicyIDByIconUrl(const std::string url) OVERRIDE;
+
+ void SetIconFileFromSystemRequest(const std::string policy_id) OVERRIDE;
+
/**
* @brief Notifies the applicaiton manager that a cloud connection status has
* updated and should trigger an UpdateAppList RPC to the HMI
@@ -383,7 +409,6 @@ class ApplicationManagerImpl
* @param app A cloud application
* @return The current CloudConnectionStatus of app
*/
-
hmi_apis::Common_CloudConnectionStatus::eType GetCloudAppConnectionStatus(
ApplicationConstSharedPtr app) const;
@@ -510,9 +535,6 @@ class ApplicationManagerImpl
// typedef for Applications list
typedef std::set<ApplicationSharedPtr, ApplicationsAppIdSorter> ApplictionSet;
- typedef std::set<ApplicationSharedPtr, ApplicationsPolicyAppIdSorter>
- AppsWaitRegistrationSet;
-
// typedef for Applications list iterator
typedef ApplictionSet::iterator ApplictionSetIt;
@@ -1002,6 +1024,14 @@ class ApplicationManagerImpl
}
};
+ struct AppNamePredicate {
+ std::string app_name_;
+ AppNamePredicate(const std::string& app_name) : app_name_(app_name) {}
+ bool operator()(const ApplicationSharedPtr app) const {
+ return app ? app->name() == app_name_ : false;
+ }
+ };
+
/**
* @brief Sends UpdateAppList notification to HMI
*/
@@ -1496,6 +1526,9 @@ class ApplicationManagerImpl
pending_device_map_lock_ptr_;
std::map<std::string, std::string> pending_device_map_;
+ sync_primitives::Lock app_icon_map_lock_ptr_;
+ std::map<std::string, AppIconInfo> app_icon_map_;
+
#ifdef TELEMETRY_MONITOR
AMTelemetryObserver* metric_observer_;
#endif // TELEMETRY_MONITOR