Use the tibasListenerCreate() function to create a listener object and associate a callback function with it.
The callback function that you specify with the callback parameter is called when you attach the listener to a metaspace on which you want to listen for events by calling the
tibasMetaspace_Listen()function or the
tibasSpace_Listen() function.
When you call tibasListenerCreate(), a listener object is created.
the listener
is then activated using the
tibasMetaspace_Listen() or
tibasSpace_Listen() functions. The callback function is passed a
tibasSpaceEvent object whose type can be determined by invoking the
tibasSpaceEvent_GetType function.
You can also specify that a current snapshot of the entries stored in the space (sometimes referred to as initial values) is prepended to the stream of events. In this case, the initial values of all the tuples contained in the space at the listener’s creation time are seen as space events of type
PUT preceding the current stream of events.