org.robokind.api.speech.utils
Class DefaultSpeechJob

java.lang.Object
  extended by org.jflux.api.core.util.DefaultNotifier<org.jflux.api.core.playable.Playable.PlayState>
      extended by org.robokind.api.speech.utils.DefaultSpeechJob
All Implemented Interfaces:
org.jflux.api.core.Notifier<org.jflux.api.core.playable.Playable.PlayState>, SpeechJob

public class DefaultSpeechJob
extends org.jflux.api.core.util.DefaultNotifier<org.jflux.api.core.playable.Playable.PlayState>
implements SpeechJob

Author:
matt

Field Summary
static int CANCELED
          The speech job has been canceled.
static int COMPLETE
          The robot has finished speaking.
static int PENDING
          Waiting for robot to begin speaking.
static int RUNNING
          The robot is speaking.
 
Fields inherited from class org.jflux.api.core.util.DefaultNotifier
myListeners
 
Method Summary
 void cancel()
          Stops the speech.
 long getSpeechJobId()
          Returns a unique id for this SpeechJob.
 String getSpeechText()
          Returns the text being spoken.
 long getStartTime()
          Returns the time the speech was queued.
 int getStatus()
          Returns the current status of the speech job.
 void setStatus(int status)
           
 void waitForSpeech()
          Halts execution until the speech is complete.
 
Methods inherited from class org.jflux.api.core.util.DefaultNotifier
addListener, notifyListeners, removeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.jflux.api.core.Notifier
addListener, notifyListeners, removeListener
 

Field Detail

PENDING

public static final int PENDING
Waiting for robot to begin speaking.

See Also:
Constant Field Values

RUNNING

public static final int RUNNING
The robot is speaking.

See Also:
Constant Field Values

COMPLETE

public static final int COMPLETE
The robot has finished speaking.

See Also:
Constant Field Values

CANCELED

public static final int CANCELED
The speech job has been canceled.

See Also:
Constant Field Values
Method Detail

getSpeechJobId

public long getSpeechJobId()
Returns a unique id for this SpeechJob.

Specified by:
getSpeechJobId in interface SpeechJob
Returns:
unique id for this SpeechJob

getSpeechText

public String getSpeechText()
Returns the text being spoken.

Specified by:
getSpeechText in interface SpeechJob
Returns:
text being spoken

getStartTime

public long getStartTime()
Returns the time the speech was queued.

Specified by:
getStartTime in interface SpeechJob
Returns:
time the speech was queued

getStatus

public int getStatus()
Returns the current status of the speech job.

Specified by:
getStatus in interface SpeechJob
Returns:
current status of the speech job

setStatus

public void setStatus(int status)
Specified by:
setStatus in interface SpeechJob

cancel

public void cancel()
Stops the speech.


waitForSpeech

public void waitForSpeech()
Halts execution until the speech is complete.



Copyright © 2011-2013. All Rights Reserved.