event_stub — event receiver service plugin
event_stub connects to the event(8gx) daemon and sets itself up to receive notifications asynchronously with the help of an extra thread. (No notifications are sent towards event(8gx) by this service plugin.)
event_stub installs one service function, "install_event_stub", with which imap(8gx) registers a callback function that, in turn, is invoked whenever a notification is received from the event daemon.
In practice, imap handles FOLDER-TOUCH and MESSAGE-FLAG notifications received through this event channel.