3 * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
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
9 * http://www.apache.org/licenses/LICENSE-2.0
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.
19 #ifndef __ACCOUNT_TYPES_H__
20 #define __ACCOUNT_TYPES_H__
29 * @addtogroup CAPI_ACCOUNT_MANAGER_MODULE
34 * @file account-types.h
35 * @ingroup CAPI_ACCOUNT
36 * @brief This file defines common types and enums of ACCOUNT.
40 * @brief Enumeration for the state of capability.
41 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
45 ACCOUNT_CAPABILITY_STATE_INVALID = 0, /**< Account capability is invalid */
46 ACCOUNT_CAPABILITY_DISABLED, /**< Account capability is disabled */
47 ACCOUNT_CAPABILITY_ENABLED, /**< Account capability is enabled */
48 ACCOUNT_CAPABILITY_STATE_MAX
50 account_capability_state_e;
53 * @brief Enumeration for the state of account secrecy.
54 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
58 ACCOUNT_SECRECY_INVALID = 0, /**< Account secrecy is invalid */
59 ACCOUNT_SECRECY_INVISIBLE, /**< Account is not visible */
60 ACCOUNT_SECRECY_VISIBLE, /**< Account is visible */
63 account_secrecy_state_e;
66 * @brief Enumeration for the account sync status.
67 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
71 ACCOUNT_SYNC_INVALID = 0, /**< Account sync is invalid */
72 ACCOUNT_SYNC_NOT_SUPPORT, /**< Account sync not supported */
73 ACCOUNT_SYNC_STATUS_OFF, /**< Account sync supported but all synchronization functionalities are off */
74 ACCOUNT_SYNC_STATUS_IDLE, /**< Account sync support and sync status is idle */
75 ACCOUNT_SYNC_STATUS_RUNNING, /**< Account sync support and sync status is running */
76 ACCOUNT_SUPPORTS_SYNC, /**< NOT USED, WILL BE REMOVED TO PREVENT BUILD ERROR */
77 ACCOUNT_NOT_SUPPORTS_SYNC, /**< NOT USED, WILL BE REMOVED TO PREVENT BUILD ERROR */
83 * @brief Enumeration for the account auth type.
84 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
88 ACCOUNT_AUTH_TYPE_INVALID = 0, /**< Auth type is invalid */
89 ACCOUNT_AUTH_TYPE_XAUTH, /**< XAuth type */
90 ACCOUNT_AUTH_TYPE_OAUTH, /**< OAuth type */
91 ACCOUNT_AUTH_TYPE_CLIENT_LOGIN, /**< Client-Login type */
96 * @brief The structure type for the Account handle.
97 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
99 typedef struct account_s* account_h;
102 * @brief The structure type for the Account provider handle.
103 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
105 typedef struct account_type_s* account_type_h;
108 * @brief The structure type for the Account handle.
109 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
111 typedef struct label_s* label_h;
114 * @brief The structure type for the Account subscribe handle.
115 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
117 typedef struct account_subscribe_s* account_subscribe_h;
120 * @brief The insert notification type.
121 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
122 * @remarks When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
124 * @see account_subscribe_notification()
126 #define ACCOUNT_NOTI_NAME_INSERT "insert"
129 * @brief The update notification type.
130 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
131 * @remarks When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
133 * @see account_subscribe_notification()
135 #define ACCOUNT_NOTI_NAME_UPDATE "update"
138 * @brief The delete notification type.
139 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
140 * @remarks When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
142 * @see account_subscribe_notification()
144 #define ACCOUNT_NOTI_NAME_DELETE "delete"
147 * @brief The sync_update notification type.
148 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
149 * @remarks When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
151 * @see account_subscribe_notification()
153 #define ACCOUNT_NOTI_NAME_SYNC_UPDATE "sync_update"
157 * @brief This is a key of app_control_h’s extra data. The value of the key is a user account name.
158 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
159 * @remarks You can retrieve the value like this, app_control_get_extra_data(app_control, ACCOUNT_DATA_USERNAME, &username).\n
160 This value will be sent with ACCOUNT_OPERATION_VIEW.
162 #define ACCOUNT_DATA_USERNAME "http://tizen.org/account/data/username"
165 * @brief This is a key of app_control_h’s extra data. The value of the key is account DB ID of the user’s account information.
166 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
167 * @remarks You can retrieve the value like this, app_control_get_extra_data(app_control, ACCOUNT_DATA_ID, &id).\n
168 This value will be sent with ACCOUNT_OPERATION_VIEW.
170 #define ACCOUNT_DATA_ID "http://tizen.org/appcontrol/data/account/id"
173 * @brief This is an application launch operation name.
174 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
175 * @remarks This operation will be sent when a user selects your account in add account view.
177 #define ACCOUNT_OPERATION_SIGNIN "http://tizen.org/appcontrol/operation/account/add"
180 * @brief This is an application launch operation name.
181 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
182 * @remarks This operation will be sent when a user selects your account in account list view.
184 #define ACCOUNT_OPERATION_VIEW "http://tizen.org/appcontrol/operation/account/configure"
187 * @brief This is contact capability string.
188 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
189 * @remarks If your provider service has contact information and contact information is provided another application, register this capability through manifest file.
191 #define ACCOUNT_SUPPORTS_CAPABILITY_CONTACT "http://tizen.org/account/capability/contact"
194 * @brief This is calendar capability string.
195 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
196 * @remarks If your provider service has calendar information and calendar information is provided another application, register this capability through manifest file.
198 #define ACCOUNT_SUPPORTS_CAPABILITY_CALENDAR "http://tizen.org/account/capability/calendar"
201 * @brief This is email capability string.
202 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
203 * @remarks If your provider service have email service and email is provided another application, register this capability through manifest file.
205 #define ACCOUNT_SUPPORTS_CAPABILITY_EMAIL "http://tizen.org/account/capability/email"
208 * @brief This is photo capability string.
209 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
210 * @remarks If your provider service has photo and photo is provided another application, register this capability through manifest file.
212 #define ACCOUNT_SUPPORTS_CAPABILITY_PHOTO "http://tizen.org/account/capability/photo"
215 * @brief This is video capability string.
216 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
217 * @remarks If your provider service has video and video is provided another application, register this capability through manifest file.
219 #define ACCOUNT_SUPPORTS_CAPABILITY_VIDEO "http://tizen.org/account/capability/video"
222 * @brief This is music capability string.
223 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
224 * @remarks If your provider service has music and music is provided another application, register this capability through manifest file.
226 #define ACCOUNT_SUPPORTS_CAPABILITY_MUSIC "http://tizen.org/account/capability/music"
229 * @brief This is document capability string.
230 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
231 * @remarks If your provider service has document and document is provided another application, register this capability through manifest file.
233 #define ACCOUNT_SUPPORTS_CAPABILITY_DOCUMENT "http://tizen.org/account/capability/document"
236 * @brief This is message capability string.
237 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
238 * @remarks This capability will be exploited to use SMS, MMS.
240 #define ACCOUNT_SUPPORTS_CAPABILITY_MESSAGE "http://tizen.org/account/capability/message"
243 * @brief This is game capability string.
244 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.4 @endif
245 * @remarks This capability will be exploited to use game data.
247 #define ACCOUNT_SUPPORTS_CAPABILITY_GAME "http://tizen.org/account/capability/game"
257 #endif /* __ACCOUNT_TYPES_H__*/