Cisco Cisco Computer Telephony Integration Option 8.5 개발자 가이드

다운로드
페이지 546
 
6-121
Cisco ICM Software CTI OS Developer’s Guide Release 6.0(0)
 
Chapter 6      Event Interfaces and Events
Events in Java CIL
where Listener is the IGenericEvents object that is subscribing for events and iListID 
is the ID of the subscriber list to add this listener to. Java subscriber list IDs are part 
of the CtiOs_Enums.SubscriberList interface; each C++/COM/VB event interface 
has a corresponding Java subscriber list (for example, C++/COM/VB ISessionEvents 
corresponds to Java eSessionList). See the Javadoc file for more details on the 
CtiOs_Enums.SubscriberList interface.
The IGenericEvents interface, though it contains the C++/COM/VB events 
documented in this chapter, does not have a callback method for each event. 
Instead, the OnEvent method passes the event ID code and arguments for each 
event. The OnEvent method has the following syntax:
void OnEvent(int iEventID, Arguments rArgs)
where iEventID is the event ID code for the event and rArgs is the arguments for 
the event. The arguments for each Java event are the same as for the 
corresponding C++/COM/VB event. See the Javadoc file for details on the 
IGenericEvents interface.
To unsubscribe for events in the Java CIL, use the RemoveEventListener method. 
This method has the following syntax:
int RemoveEventListener(IGenericEvents Listener, int iListID)
where Listener is the IGenericEvents object that is unsubscribing for events and 
iListID is the ID of the subscriber list to remove this listener from.