3 * Copyright (c) 2012 Samsung Electronics Co., Ltd.
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.
21 #define EVENT_MAX_EVENT_COUNT 100
22 #define EVENT_MAX_NOTI_COUNT 100
26 * @brief Definition of Event / Noti spec codes for event module
34 * @brief Enumerations for event type
37 EVENT_TYPE_UNKNOWN = -1, /**< unknown */
38 EVENT_TYPE_NO_RESPONSE = 0, /**< just send event, no response - will be removed */
39 EVENT_TYPE_NEED_RESPONSE, /**< send event & wait for response for sent event - synchronous processing */
43 * @brief Enumerations for notification type
46 NOTI_TYPE_UNKNOWN = -1, /**< unknown */
47 NOTI_TYPE_SIMPLE = 0, /**< just send noti, no response */
51 * @brief Structure for event spec in event config file
54 int event_num; /**< event number */
55 event_type_e event_type; /**< event type */
56 int relational_noti_num; /**< noti number associated with event number */
57 int pendingtime; /**< pending time for response */
58 sync_agent_event_cb callback; /**< event callback function */
62 * @brief Structure for noti spec in noti config file
65 int noti_num; /**< noti number */
66 noti_type_e noti_type; /**< noti type */
67 int relational_event_num; /**< event number associated with noti number */
68 int pendingtime; /**< pending time for response */
69 void *additional_param; /**< additional data used in sync_agent_noti_cb */
70 sync_agent_noti_cb callback; /**< noti callback function */
74 * @brief Structure to manage noti spec
77 char *noti_key; /**< destination, described in framework initialization config file /<Noti> tag */
78 char *communication_path_noti; /**< noti path */
79 char *communication_path_reply_noti; /**< noti reply path - will be removed */
80 int noti_count; /**< total number of noti */
81 noti_spec_s *noti_spec_list[EVENT_MAX_NOTI_COUNT]; /**< list of noti spec */