Initialize Tizen 2.3
[framework/system/deviced.git] / src / deviced / dd-storage.h
1 /*
2  * deviced
3  *
4  * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd.
5  *
6  * Licensed under the Apache License, Version 2.0 (the License);
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  *     http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */
18
19
20 #ifndef __DD_STORAGE_H__
21 #define __DD_STORAGE_H__
22
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26
27 /**
28  * @file        dd-storage.h
29  * @defgroup    CAPI_SYSTEM_DEVICED_STORAGE_MODULE Storage
30  * @ingroup     CAPI_SYSTEM_DEVICED
31  * @brief       This file provides the API for control of storage
32  * @section CAPI_SYSTEM_DEVICED_STORAGE_MODULE_HEADER Required Header
33  *   \#include <dd-storage.h>
34  */
35
36 /**
37  * @addtogroup CAPI_SYSTEM_DEVICED_STORAGE_MODULE
38  * @{
39  */
40
41 /**
42  * @par Description
43  * Storage path type
44  */
45 enum storage_path_type {
46         STORAGE_DEFAULT = 0,
47         STORAGE_INTERNAL,
48         STORAGE_EXTERNAL,
49         STORAGE_MAX,
50 };
51
52 /**
53  * @par Description:
54  *  This API is used go get storage path.\n
55  * @param[in] type storage path type
56  * @param[in] path pointer to a buffer where the path is stored
57  * @param[in] size size of buffer
58  * @return 0 on success, -1 if failed
59  * @see storage_path_type
60  * @par Example
61  * @code
62  *  ...
63  *  if ( storage_get_path(STORAGE_INTERNAL, path, 50) < 0 )
64  *          printf("Get storage path failed\n");
65  *  ...
66  * @endcode
67  */
68 int storage_get_path(int type, unsigned char *path, int size);
69
70 /**
71  * @} // end of CAPI_SYSTEM_DEVICED_STORAGE_MODULE
72  */
73
74 #ifdef __cplusplus
75 }
76 #endif
77 #endif