2 * Samsung Ukraine R&D Center (SRK under a contract between)
3 * LLC "Samsung Electronics Co", Ltd (Seoul, Republic of Korea)
4 * Copyright (C) 2018 Samsung Electronics Co., Ltd. All rights reserved.
7 * @file application_service.h
8 * @brief Class for software installation and maintenance
9 * @date Created Jul 28, 2017
10 * @author Mail to: <A HREF="mailto:i.metelytsia@samsung.com">Iurii Metelytsia, i.metelytsia@samsung.com</A>
13 #ifndef __APPLICATION_SERVICE_H__
14 #define __APPLICATION_SERVICE_H__
22 * @brief The ApplicationService class is designed to install and maintain software
24 class ApplicationService
29 * @brief Install package
30 * @details This API can be used to install RPM package
31 * @param package_path_name [in] RPM package full pathname
32 * @return 0 if success
34 static int install(const std::string& package_path_name);
37 * @brief Uninstall package
38 * @details This API can be used to uninstall RPM package
39 * @param package_name [in] RPM package name
40 * @return 0 if success
42 static int uninstall(const std::string& package_name);
45 * @brief Find process id by application name
46 * @details This API can be used to find out process id
47 * @param name [in] application name
48 * @return process id or -1
50 static int get_process_id_by_name(const std::string& name);
53 * @brief Power off the device
54 * @details This API can be used to power off the device
55 * @return 0 if success
57 static int device_power_off();
63 #endif /* __APPLICATION_SERVICE_H__ */