Provides access to Interactions and InteractionQueues.

Namespace: ININ.IceLib.Interactions
Assembly: ININ.IceLib.Interactions (in ININ.IceLib.Interactions.dll) Version: 0.0.0.0 (22.3.0.218)

Syntax

C#
public class InteractionsManager
Visual Basic
Public Class InteractionsManager

Remarks

Use the InteractionsManager class to access the functionality found in the ININ.IceLib.Interactions namespace.

The ININ.IceLib.Interactions namespace includes all functionality for manipulating interactions and interaction queues managed by an IC server. Most features provided in the InteractionsManager are available in synchronous and asynchronous versions allowing you to choose the model that best suits your needs. The asynchronous versions are preferred since these operations can be lengthy and block the calling thread.


Examples

All "manager" classes found in the IceLib library are designed as singletons. To begin working with any of the functionality provided in the InteractionsManager you must obtain the instance through a call to GetInstance(Session).
CopyC#
Session session = new Session();
session.Connect(...);
InteractionsManager interactionsManager = InteractionsManager.GetInstance(session);

Examples

The following example illustrates using this class to make a call.
CopyC#
...

string _PhoneNumber = "555-1212";

private void btMakeCall_Click(object sender, System.EventArgs e)
{
    if (_Session.ConnectionState != ConnectionState.Up)
    {
        MessageBox.Show("Connection is down");
        return;
    }        
    _InteractionsManager.MakeCallAsync(
        new CallInteractionParameters(_PhoneNumber),
        new EventHandler<InteractionCompletedArgs>(InteractionsManager_MakeCallCompleted),
        null);
}

private void InteractionsManager_MakeCallCompleted(object sender, InteractionCompletedEventArgs e)
{
    if (e.Error != null)
    {
        MessageBox.Show(e.Error.StackTrace, e.Error.Message);
        return;
    }

    Interaction interaction = e.Interaction;

    _LastInteraction = interaction;

    if (interaction != null)
    {
        MessageBox.Show(String.Format("Call Made. InteractionId={0}", interaction.InteractionId);
    }
    else
    {
        MessageBox.Show("MakeCall Failed.");
    }
 }

Inheritance Hierarchy

System..::..Object
  ININ.IceLib.Interactions..::..InteractionsManager

Version Information

Supported for IC Server version 2015 R1 and beyond.
For 4.0, supported for IC Server version 4.0 GA and beyond.
For 3.0, supported for IC Server version 3.0 GA and beyond.

See Also