2 * Copyright (c) 2000 - 2016 Samsung Electronics Co., Ltd. All rights reserved.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 #ifndef __NOTIFICATION_STATUS_INTERNAL_DEF_H__
18 #define __NOTIFICATION_STATUS_INTERNAL_DEF_H__
22 #endif /* __cplusplus */
25 * @file notification_status_internal.h
29 * @addtogroup NOTIFICATION_STATUS
35 * @brief Unregisters a callback for all notification events.
36 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
38 * @privilege %http://tizen.org/privilege/notification
39 * @param[in] changed_cb The callback function
40 * @return #NOTIFICATION_ERROR_NONE on success,
41 * otherwise any other value on failure
42 * @retval #NOTIFICATION_ERROR_NONE Success
43 * @retval #NOTIFICATION_ERROR_INVALID_PARAMETER Invalid parameter
44 * @retval #NOTIFICATION_ERROR_PERMISSION_DENIED The application does not have the privilege to call this method
45 * @see notification_register_detailed_changed_cb()
48 #include <notification.h>
51 noti_err = notification_register_detailed_changed_cb(app_changed_cb, user_data);
52 if(noti_err != NOTIFICATION_ERROR_NONE) {
58 int notification_unregister_detailed_changed_cb(
59 void (*detailed_changed_cb)(void *data, notification_type_e type, notification_op *op_list, int num_op),
64 * @brief Called when a new message is posted.
65 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
66 * @param[in] message The message posted
67 * @param[in] data The user data
68 * @pre notification_status_monitor_message_cb_set() used to register this callback.
69 * @see notification_status_monitor_message_cb_set()
71 typedef void (*notification_status_message_cb)(const char *message, void *data);
75 * @brief Registers a callback to receive a message.
76 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
77 * @param[in] callback The callback function
78 * @param[in] data The user_data
79 * @return #NOTIFICATION_ERROR_NONE if success, other value if failure
80 * @retval #NOTIFICATION_ERROR_NONE Success
81 * @retval #NOTIFICATION_ERROR_INVALID_PARAMETER Invalid parameter
82 * @retval #NOTIFICATION_ERROR_FROM_DBUS Error from DBus
84 int notification_status_monitor_message_cb_set(notification_status_message_cb callback, void *user_data);
88 * @brief Unregisters a callback to receive a message.
89 * @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
90 * @param[in] callback The callback function
91 * @param[in] data The user_data
92 * @return #NOTIFICATION_ERROR_NONE if success, other value if failure
93 * @retval #NOTIFICATION_ERROR_NONE Success
95 int notification_status_monitor_message_cb_unset(void);
103 #endif /* __cplusplus */
104 #endif /* __NOTIFICATION_STATUS_INTERNAL_DEF_H__ */