blob: 0578373d323a81a4e0ba6cca9b7be0bddb37ed54 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
|
/*
* libslp-sysman
*
* Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
*
* Contact: DongGi Jang <dg0402.jang@samsung.com>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
#ifndef ___SYSMAN_MANAGED___
#define ___SYSMAN_MANAGED___
#include <sys/time.h>
/**
* @file sysman_managed.h
* @ingroup libsysman System Manager library
* @brief This library provides APIs related with memory, performance, processes, and so on.
* @author SLP2.0
* @date 2010-01-24
* @version 0.1
*/
/**
* @fn int sysman_get_pid(const char *execpath)
* @brief This API is used to get the pid of the process which has the specified execpath.\n
* Internally, this API searches /proc/{pid}/cmdline and compares the parameter execpath with 1st argument of cmdline. \n
* If there is no process that has same execpath in /proc/{pid}/cmdline, it will return -1.
* @param[in] execpath program path which you want to know whether it is run or not
* @return pid when the program is running, -1 if it is not.
*/
int sysman_get_pid(const char *execpath);
/**
* @fn int sysman_set_datetime(time_t timet)
* @brief This API is used to set date time.\n
* Internally, this API call predefined action API. That is send a notify message. \n
* @param[in] time_t type of time which you want to set.
* @return pid when the program is running, -1 if param is less than 0 or when failed set datetime.
*/
int sysman_set_datetime(time_t timet);
#endif /* ___SYSMAN_MANAGED___ */
|