APPLY_RSA
[apps/home/libslp-alarm.git] / kies_alarm / include / kies_alarm.h
1 /*
2 *
3 * Copyright 2012  Samsung Electronics Co., Ltd
4 *
5 * Licensed under the Flora License, Version 1.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 *    http://www.tizenopensource.org/license
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 *
17 */
18 #ifndef __KIES_ALARM_H__
19 #define __KIES_ALARM_H__
20
21 #define KIES_ALM_SUCCESS 0
22 #define KIES_ALM_FAILED -1
23
24 /*return value*/
25 enum {
26         RESULT_FAILED = KIES_ALM_FAILED,
27         RESULT_SUCCESS = KIES_ALM_SUCCESS,
28         RESULT_ERR_NULL_ALARM,  /*don't alarm in phone, not save */
29 };
30 /**
31  * @def A_DBAPI
32  * prefix
33  */
34 #ifndef A_DBAPI
35 #define A_DBAPI __attribute__ ((visibility("default")))
36 #endif
37 /**
38  * @def VCONFKEY_ALARM_RESTORE
39  * when restore alarm, send the message to notify the alarm data changed.
40  * It could be get by  use vconf_ignore_key_changed
41  */
42 #define VCONFKEY_ALARM_RESTORE "memory/alarm/restore"
43
44 /**
45  * This function backup alarm data, the data will be saved to @param
46  * If the file path is NULL, return FAILED
47  *
48  * @brief       backup alarm data
49  *
50  * @param       [in]   file_path    the path of user want to save data
51  *
52  * @return     On success, SUCCESS is returned. On error, FAILED is returned
53  *             if phone don't save any alarm,  RESULT_ERR_NULL_ALARM is returned.
54  *
55  * @remarks
56  *
57  * @exception
58  *
59  * @see alarm_restore
60  *
61  */
62 A_DBAPI int alarm_backup(const char *file_path);
63
64 /**
65  * This function restore alarm data, the data is from @param
66  * If the file path is NULL, return FAILED
67  *
68  * @brief       backup alarm data
69  *
70  * @param       [in]   file_path    the path of user want to get data
71  *
72  * @return     On success, SUCCESS is returned. On error, FAILED is returned
73  *
74  * @remarks
75  *
76  * @exception
77  *
78  * @see alarm_backup
79  *
80  */
81 A_DBAPI int alarm_restore(const char *file_path);
82
83 #endif/*__KIES_ALARM_H__*/