RDK Documentation (Open Sourced RDK Components)
hostIf_NotificationHandler.h
1 /*
2  * If not stated otherwise in this file or this component's Licenses.txt file the
3  * following copyright and licenses apply:
4  *
5  * Copyright 2017 RDK Management
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18 */
19 
20 /**
21 * @defgroup tr69hostif
22 * @{
23 * @defgroup hostif
24 * @{
25 **/
26 
27 
28 #ifndef _HOSTIF_NOTIFICATION_HANDLER_H_
29 #define _HOSTIF_NOTIFICATION_HANDLER_H_
30 
31 
32 #include "hostIf_main.h"
33 #include "hostIf_tr69ReqHandler.h"
34 
35 typedef void (*parodusNotificationCallback)();
36 
38 {
39 private:
40  static NotificationHandler *pInstance;
41  static parodusNotificationCallback notifyUpdateCallback;
42  static GAsyncQueue *notificationQueue;
43 
46 
47  void pushNotification(const char* destination, const char* payload);
48 
49 public:
50  static NotificationHandler* getInstance();
51  static GAsyncQueue* GetNotificationQueue();
52  static void registerUpdateCallback(parodusNotificationCallback cb);
53 
54  void pushValueChangeNotification(IARM_Bus_tr69HostIfMgr_EventData_t& event);
55  void pushKeyValueNotification(const char* destination, const char* key, const char* value);
56  void push_device_mgmt_notifications(char* delay, char* startTime, char* dwnldStatus, char* status, char* systemReadyTime);
57 
58 };
59 
60 #endif //_HOSTIF_NOTIFICATION_HANDLER_H_
61 
62 
63 /** @} */
64 /** @} */
NotificationHandler
Definition: hostIf_NotificationHandler.h:37
_tr69HostIfMgr_EventData_t
Definition: hostIf_tr69ReqHandler.h:195
hostIf_main.h
hostIf_main API.