Brew advanced and proficient-3G mobile value-added business operation, customization and Development serialized 80--callback notification for inter-brew Communication

Source: Internet
Author: User

The aee layer supports the concept of notification. Notification is a mechanism in which different applications can be registered for the event to handle certain errors in other applications. For example, you can register an application to receive notifications when there is an incoming SMS message. This means that as long as there is an incoming SMS message, the application that has registered to receive the notification will receive an event, which is evt_policy. A notification program is an application that generates a notification. For example, an itapi can act as a notification program. A notification will be sent when an incoming SMS message is sent. Whenever the notification program needs to send a notification, it must use the ishell_policy () method. The application can receive notifications through registration. To do so, the ishell_registernotify () function is generally used (). For example, an application can use ishell_registernotify () to register and receive notifications of such specific events from the aeeclsid_tapi.

Inotifier is a function interface that must be implemented by the application that needs to become a notification program. Any application that wants to send a notification so that other applications can receive it must implement functions in the inotifier interface, implement the inotifier interface, and define the notification (or mask) group that can be sent by this class, 0 xffffffff indicates that all notifications are received, and 0x00000000 indicates that all notifications are not received. For example, nmask_tapi_sms, nmask_tapi_ts_page, nmask_tapi_ts_vmail, and Other types can be sent by TAPI. These masks must be available to other applications so that the applications that follow these notifications can register them. The notification program must call the ishell_policy () function whenever a notification is sent. At this time, the aee layer is responsible for notifying all applications that have registered to receive the notification.

After brew 3.1.4, the ialarmmgr interface is introduced. One application can use alarm settings to notify another application to perform related operations. Compared with ishell_setalarm, ialarmmgr can set the alarm trigger interval in seconds, and can be set based on the specified time or absolute time. An important feature of ialarmmgr is that you can retain a unique alarm code before setting an alarm to trigger. The alarm code is a 16-bit integer. You can use ialarmmgr_setusercode () and ialarmmgr_getusercode () to set and obtain the alarm code. You can use ialarmmgr_setalarm () to specify a valid classid so that another application can receive an alarm. The application that receives the alarm listens to the evt_alarm event. wparam is the alarm code, then you can perform related operations.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.