com.voicent.webalert
Class Voicent

java.lang.Object
  extended bycom.voicent.webalert.Voicent

public class Voicent
extends java.lang.Object


Constructor Summary
Voicent()
          Constructor with default localhost:8155
Voicent(java.lang.String host, int port)
          Constructor with Voicent gateway hostname and port.
 
Method Summary
 java.lang.String callAudio(java.lang.String phoneno, java.lang.String audiofile, boolean selfdelete)
          Make a call to the number specified and play the audio file.
 void callRemove(java.lang.String reqID)
          Remove all request from the gateway
 java.lang.String callStatus(java.lang.String reqID)
          Get call status of the call with the reqID.
 java.lang.String callText(java.lang.String phoneno, java.lang.String text, boolean selfdelete)
          Make a call to the number specified and play the text message using text-to-speech engine.
 void callTillConfirm(java.lang.String vcastexe, java.lang.String vocfile, java.lang.String wavfile, java.lang.String ccode)
          Invoke BroadcastByPhone and start the call-till-confirm process
static void main(java.lang.String[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Voicent

public Voicent()
Constructor with default localhost:8155


Voicent

public Voicent(java.lang.String host,
               int port)
Constructor with Voicent gateway hostname and port.

Parameters:
host - Voicent gateway host machine
port - Voicent gateway port number
Method Detail

callText

public java.lang.String callText(java.lang.String phoneno,
                                 java.lang.String text,
                                 boolean selfdelete)
Make a call to the number specified and play the text message using text-to-speech engine.

Parameters:
phoneno - Phone number to call, exactly as it should be dialed
text - Text to play over the phone using text-to-speech
selfdelete - After the call, delete the call request automatically if set to 1
Returns:
Call request ID

callAudio

public java.lang.String callAudio(java.lang.String phoneno,
                                  java.lang.String audiofile,
                                  boolean selfdelete)
Make a call to the number specified and play the audio file. The audio file should be of PCM 8KHz, 16bit, mono.

Parameters:
phoneno - Phone number to call, exactly as it should be dialed
audiofile - Audio file path name
selfdelete - After the call, delete the call request automatically if set to 1
Returns:
Call request ID

callStatus

public java.lang.String callStatus(java.lang.String reqID)
Get call status of the call with the reqID.

Parameters:
reqID - Call request ID on the gateway
Returns:
call status

callRemove

public void callRemove(java.lang.String reqID)
Remove all request from the gateway

Parameters:
reqID - Call request ID on the gateway
Returns:
call status

callTillConfirm

public void callTillConfirm(java.lang.String vcastexe,
                            java.lang.String vocfile,
                            java.lang.String wavfile,
                            java.lang.String ccode)
Invoke BroadcastByPhone and start the call-till-confirm process

Parameters:
vcastexe - Executable file vcast.exe, BroadcastByPhone path name
vocfile - BroadcastByPhone call list file
wavfile - Audio file used for the broadcast
ccode - Confirmation code

main

public static void main(java.lang.String[] args)
                 throws java.lang.InterruptedException
Throws:
java.lang.InterruptedException