Advanced IVR Tutorial Lesson 1: Create a Java Action

The Select Call List element is also used to run a Java action to get a list of available call list files. The call lists are presented to the caller for selection. In Part I of this tutorial, the call list file name is hard coded as C:\Call List\mylist.voc.

To simplify this sample we assume there are less than 10 call lists, so we can use one single touch tone key to select from a list.

Create a Java Action

Select Select Call List element, click the properties button on the program toolbar then select the Action tab. Click the New button. From Choose Action Type window, select Call Java Method radio button.

This Java action defines calling a Java method. It specifies that the system should invoke the get method of class voicent.ivrsample.IvrSampleGetFiles. The class is defined in the jar file: "ivrsample.jar". From the parameter list, we can see that the method signature is get(String, String) and it will be invoked as get("C:\Call List", ".voc"). The first argument is the directory to fetch the files and the second argument is the file extension used to filter the listing.