summaryrefslogtreecommitdiff
path: root/src/components/application_manager/include/application_manager/resumption/resume_ctrl.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/application_manager/include/application_manager/resumption/resume_ctrl.h')
-rw-r--r--src/components/application_manager/include/application_manager/resumption/resume_ctrl.h35
1 files changed, 30 insertions, 5 deletions
diff --git a/src/components/application_manager/include/application_manager/resumption/resume_ctrl.h b/src/components/application_manager/include/application_manager/resumption/resume_ctrl.h
index 0ec58f2419..f9a60c862b 100644
--- a/src/components/application_manager/include/application_manager/resumption/resume_ctrl.h
+++ b/src/components/application_manager/include/application_manager/resumption/resume_ctrl.h
@@ -34,14 +34,14 @@
#define SRC_COMPONENTS_APPLICATION_MANAGER_INCLUDE_APPLICATION_MANAGER_RESUMPTION_RESUME_CTRL_H_
#include <stdint.h>
-#include "utils/shared_ptr.h"
+#include <time.h>
#include "application_manager/resumption/resumption_data.h"
namespace application_manager {
class ApplicationManager;
class Application;
-typedef utils::SharedPtr<Application> ApplicationSharedPtr;
-typedef utils::SharedPtr<const Application> ApplicationConstSharedPtr;
+typedef std::shared_ptr<Application> ApplicationSharedPtr;
+typedef std::shared_ptr<const Application> ApplicationConstSharedPtr;
}
namespace app_mngr = application_manager;
@@ -125,6 +125,16 @@ class ResumeCtrl {
virtual void OnAwake() = 0;
/**
+ * @brief Saves Low Voltage signal timestamp
+ */
+ virtual void SaveLowVoltageTime() = 0;
+
+ /**
+ * @brief Saves Wake Up signal timestamp
+ */
+ virtual void SaveWakeUpTime() = 0;
+
+ /**
* @brief Checks if SDL has already received OnExitAllApplication notification
* with "SUSPEND" reason
*
@@ -134,13 +144,19 @@ class ResumeCtrl {
virtual bool is_suspended() const = 0;
/**
- * @brief Method stops timer "RsmCtrlPercist" when SDL
+ * @brief Method stops timer "RsmCtrlPersist" when SDL
* receives OnExitAllApplication notification
* with reason "SUSPEND"
*/
virtual void StopSavePersistentDataTimer() = 0;
/**
+ * @brief Method starts timer "RsmCtrlPersist" when
+ * SDL receives onAwakeSDL notification
+ */
+ virtual void StartSavePersistentDataTimer() = 0;
+
+ /**
* @brief Start timer for resumption applications
* Restore D1-D5 data
* @param application that is need to be restored
@@ -158,6 +174,13 @@ class ResumeCtrl {
app_mngr::ApplicationSharedPtr application) = 0;
/**
+ * @brief Retry resumption of an app if it has been disabled or limited
+ * due to absence of high-bandwidth transport.
+ * @param app_id ID of the app to resume
+ */
+ virtual void RetryResumption(const uint32_t app_id) = 0;
+
+ /**
* @brief Check if there are all files need for resumption
* @param application that is need to be restored
* @return true if it all files exist, otherwise return false
@@ -263,7 +286,9 @@ class ResumeCtrl {
#ifdef BUILD_TESTS
virtual void set_resumption_storage(
- utils::SharedPtr<ResumptionData> mock_storage) = 0;
+ std::shared_ptr<ResumptionData> mock_storage) = 0;
+
+ virtual bool get_resumption_active() const = 0;
#endif // BUILD_TESTS
};