Tizen 2.0 Release
[pkgs/o/oma-ds-service.git] / include / service-adapter / sa_devinf.h
1 /*
2  * oma-ds-agent
3  * Copyright (c) 2012 Samsung Electronics Co., Ltd.
4  *
5  * Licensed under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0
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 /**
19  *   @SA_DevInf.h
20  *   @version                                                                   0.1
21  *   @brief                                                                             This file is the header file of interface of DevInf structure
22  */
23
24 #ifndef SA_DEVINF_H_
25 #define SA_DEVINF_H_
26
27 #include "service-adapter/sa_define.h"
28
29 /**
30  * @par Description: API to create devinf_s structure
31  *
32  * @par Purpose:
33  * @par Typical use case:
34  * @par Method of function operation:
35  * @par Important notes:
36  * @param[in]           session_s structure
37  * @param[out]          devinf_s  structure
38  *
39  * @return                      ERROR_INTERNAL_OK on success
40  *                                              ERROR_INTERNAL_ERROR, ERROR_INTERNAL_NOT_DEFINED, ERROR_INTERNAL_NO_MEMORY on error
41  *
42  * @par Errors:
43  *
44  * @pre None.
45  * @post
46  * @see
47  * @remarks None.
48  *
49  * @par Sample Code:
50  * @code
51  * @endcode
52  */
53 sa_error_type_e create_devinf(session_s * session, devinf_s ** devinf);
54
55 /**
56  * @par Description: API to free devinf_s structure
57  *
58  * @par Purpose:
59  * @par Typical use case:
60  * @par Method of function operation:
61  * @par Important notes:
62  * @param[in]           devinf_s  structure
63  *
64  * @return
65  *
66  * @par Errors:
67  *
68  * @pre None.
69  * @post
70  * @see
71  * @remarks None.
72  *
73  * @par Sample Code:
74  * @code
75  * @endcode
76  */
77 void free_devinf(devinf_s * devinf);
78
79 /**
80  * @par Description: API to set sync cap in devinf_datastore_s structure
81  *
82  * @par Purpose:
83  * @par Typical use case:
84  * @par Method of function operation:
85  * @par Important notes:
86  * @param[in]           devinf_datastore_s structure
87  * @param[in]           devinf_sync_cap_e sync type
88  * @param[in]           whether support or not
89  *
90  * @return
91  *
92  * @par Errors:
93  *
94  * @pre None.
95  * @post
96  * @see
97  * @remarks None.
98  *
99  * @par Sample Code:
100  * @code
101  * @endcode
102  */
103 void set_devinf_datastore_sync_cap(devinf_datastore_s * devinf_datastore, devinf_sync_cap_e cap, int supported);
104
105 /**
106  * @par Description: API to get sync cap from devinf_datastore_s structure
107  *
108  * @par Purpose:
109  * @par Typical use case:
110  * @par Method of function operation:
111  * @par Important notes:
112  * @param[in]           devinf_datastore_s structure
113  * @param[in]           devinf_sync_cap_e sync type
114  *
115  * @return                              True on success
116  *                                                      False on error
117  *
118  * @par Errors:
119  *
120  * @pre None.
121  * @post
122  * @see
123  * @remarks None.
124  *
125  * @par Sample Code:
126  * @code
127  * @endcode
128  */
129 int get_devinf_datastore_sync_cap(const devinf_datastore_s * devinf_datastore, devinf_sync_cap_e cap);
130
131 /*
132 DevInfSyncCap convert_devinf_synccap(unsigned int id);
133 */
134 #endif                          /* SA_DEVINF_H_ */