Cisco Cisco Computer Telephony Integration Option 9.0 Developer's Guide

Page of 500
   
4-77
CTI OS Developer’s Guide for Cisco ICM/IPCC Enterprise & Hosted Editions
Cisco CTI OS Release 7.2(1)
Chapter 4      Building Your Application
Building Supervisor Applications
An agent involved in a call will not be logged out until the agent is disconnected from the call.  Both the 
out-of-the-box desktop and the combo desktop warn the supervisor of this behavior.  This can be done 
by checking the state of the currently monitored agent.  If the agent’s state is talking, hold, or reserved 
the monitored agent is involved in one or more calls and will not be logged out until the agent has been 
disconnected from all calls.  This is illustrated in SupervisorUIManager.m_btnMonLogoutAgentClick().
Successfully calling Agent.SetAgentState() should be followed by one or more 
SupervisorButtonChange and MonitoredAgentEvents reflecting the change in the monitored agent’s 
state.
Monitoring Calls
This section discusses step 4 in the flow of a supervisor application.  The methods and events listed 
below are used to monitor a call.
Methods Called
Agent.StartMonitoringCall()
 
Agent.SuperviseCall()
Events Processed
Events Processed
 
OnSupervisorButtonChange
 
AgentStateEvents
 
CallEvents
 
MonitoredCallEvents
MonitoredCallEvents
As stated in the “Monitoring Agents” section, calling Agent.StartMonitoringAgent() will trigger 
MonitoredCallEvents for the agent specified in Agent.StartMonitoringAgent().  The 
MonitoredCallEvents received by the supervisor desktop, inform the desktop of the state of the 
monitored agent’s calls.  The combo desktop uses these events to populate and update the monitored calls 
grid.  Please see the SupervisorUIManager and CallAppearanceHelper classes for further details.
To monitor a given call, the supervisor calls the Agent.StartMonitoringCall() method.  The target of the 
call is the current agent (Agent object representing the supervisor).  StartMonitoringCall() takes an 
Arguments object with the CallReference key set to the UniqueObjectID of the call to be monitored.  
This is illustrated in the CTIObject.StartMonitoringCall()method.
AgentState
The state to which to set the agent.  In 
this case, the state is ready (integer 
with value 3).
EventReasonCode
The value associated with this key is 
999.  The value 999 indicates to the rest 
of IPCC that the agent was logged out 
by their supervisor.
Key
Value