com.cloudgarden.speech
Class CGResultAudioClip

java.lang.Object
  |
  +--com.cloudgarden.speech.CGResultAudioClip
All Implemented Interfaces:
java.applet.AudioClip

public class CGResultAudioClip
extends java.lang.Object
implements java.applet.AudioClip

Allows audio data from a recognized utterance to be played back or saved to a WAVE file.


Constructor Summary
CGResultAudioClip(com.cloudgarden.speech.CGRecognizer rec, long eventID, CGResult res)
          Creates new CGResultAudioClip
CGResultAudioClip(com.cloudgarden.speech.CGRecognizer rec, long eventID, int start, int length, CGResult res)
           
 
Method Summary
 void loop()
           
 void play()
           
 void saveToFile(java.lang.String fileName)
          Allows the audio data from a recognized sample of speech to be saved to a file - the fileName parameter should be the name (new or already existing) of a WAVE file.
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CGResultAudioClip

public CGResultAudioClip(com.cloudgarden.speech.CGRecognizer rec,
                         long eventID,
                         CGResult res)
Creates new CGResultAudioClip

CGResultAudioClip

public CGResultAudioClip(com.cloudgarden.speech.CGRecognizer rec,
                         long eventID,
                         int start,
                         int length,
                         CGResult res)
Method Detail

loop

public void loop()
Specified by:
loop in interface java.applet.AudioClip

play

public void play()
Specified by:
play in interface java.applet.AudioClip

saveToFile

public void saveToFile(java.lang.String fileName)
Allows the audio data from a recognized sample of speech to be saved to a file - the fileName parameter should be the name (new or already existing) of a WAVE file. Will do nothing if no audio data is available.

stop

public void stop()
Specified by:
stop in interface java.applet.AudioClip