org.robokind.api.speech
Interface SpeechService


public interface SpeechService

The SpeechService provides a basic interface for an service providing Text-to-Speech or equivalent capabilities.

Author:
Matthew Stevenson

Method Summary
 void addRequestListener(org.robokind.api.common.utils.Listener<SpeechRequest> listener)
          Adds a Listener to be notified when a speech request is made.
 void addSpeechEventListener(org.robokind.api.common.utils.Listener<SpeechEventList> listener)
          Adds a Listener to be notified when a speech event occurs.
 void close()
          Closes a SpeechService, leaving it unable to speak.
 void removeRequestListener(org.robokind.api.common.utils.Listener<SpeechRequest> listener)
          Removes a Listener from being notified when a speech request is made.
 void removeSpeechEventListener(org.robokind.api.common.utils.Listener<SpeechEventList> listener)
          Removes a Listener from being notified when a speech event occurs.
 void speak(String text)
          Sends the SpeechService text to speak.
 void start()
          Starts the SpeechService, making it ready to speak.
 

Method Detail

start

void start()
           throws Exception
Starts the SpeechService, making it ready to speak.

Throws:
Exception

speak

void speak(String text)
Sends the SpeechService text to speak.

Parameters:
text - the text to speak

close

void close()
Closes a SpeechService, leaving it unable to speak.


addRequestListener

void addRequestListener(org.robokind.api.common.utils.Listener<SpeechRequest> listener)
Adds a Listener to be notified when a speech request is made.

Parameters:
listener - the Listener to be notified

removeRequestListener

void removeRequestListener(org.robokind.api.common.utils.Listener<SpeechRequest> listener)
Removes a Listener from being notified when a speech request is made.

Parameters:
listener - the Listener to remove

addSpeechEventListener

void addSpeechEventListener(org.robokind.api.common.utils.Listener<SpeechEventList> listener)
Adds a Listener to be notified when a speech event occurs.

Parameters:
listener - the Listener to be notified

removeSpeechEventListener

void removeSpeechEventListener(org.robokind.api.common.utils.Listener<SpeechEventList> listener)
Removes a Listener from being notified when a speech event occurs.

Parameters:
listener - the Listener to remove


Copyright © 2011. All Rights Reserved.