Cisco Cisco Computer Telephony Integration Option 8.5 Guía Del Desarrollador
Chapter 8 Session Object
Methods
8-20
CTI OS Developer’s Guide for Cisco ICM/IPCC Enterprise & Hosted Editions Release 7.0(0)
The following sample VB.NET code illustrates how to take the array returned
from GetAllAgents() and use it to access the corresponding agents in the CIL’s
object cache. The example uses the .NET CIL.
from GetAllAgents() and use it to access the corresponding agents in the CIL’s
object cache. The example uses the .NET CIL.
Dim args As Arguments
args = m_session.GetAllAgents()
' Iterate through all of the CILRefArg objects
' in the Arguments array.
'
Dim i As Integer
For i = 1 To args.NumElements()
Dim refArg As CilRefArg
' Retrieve the CILRefArg at each position in the
' array.
'
If (args.GetElement(i, refArg)) Then
If ((refArg Is Nothing) = False) Then
' The value method will return a reference
' to the agent object referenced by the
' CILRefArg.
'
Dim agent As Agent
refArg.GetValue(agent)
Console.Out.WriteLine("--")
If (agent Is Nothing) Then
Console.Out.WriteLine("Nothing")
Else
Console.Out.WriteLine(agent.DumpProperties())
End If
Console.Out.WriteLine("--")
End If
End If
Next