org.robokind.api.speech
Interface SpeechEvent


public interface SpeechEvent

Defines a common interface for several types of Speech events. Some examples of events are word start and end events, or phoneme events.

Author:
Matthew Stevenson

Method Summary
 Integer getCurrentData()
          Returns event data (usually phone or viseme id) associated with the start of the event.
 Integer getDuration()
          Returns the duration of the event in milliseconds.
 Integer getNextData()
          Returns event data (usually phone or viseme id) associated with the end of the event.
 String getSpeechEventType()
          Returns the name of the event of this event.
 Long getStreamNumber()
          Returns the stream number for tts output the event originates from.
 String getStringData()
          Returns any String data associated with the event (used for SAPI bookmark events).
 Integer getTextLength()
          Returns the number of characters the event covers.
 Integer getTextPosition()
          Returns the position of the speech request the event begins at.
 

Method Detail

getSpeechEventType

String getSpeechEventType()
Returns the name of the event of this event.

Returns:
name of the event of this event

getStreamNumber

Long getStreamNumber()
Returns the stream number for tts output the event originates from.

Returns:
stream number for tts output the event originates from

getTextPosition

Integer getTextPosition()
Returns the position of the speech request the event begins at.

Returns:
position of the speech request the event begins at

getTextLength

Integer getTextLength()
Returns the number of characters the event covers.

Returns:
number of characters the event covers

getCurrentData

Integer getCurrentData()
Returns event data (usually phone or viseme id) associated with the start of the event.

Returns:
event data (usually phone or viseme id) associated with the start of the event

getNextData

Integer getNextData()
Returns event data (usually phone or viseme id) associated with the end of the event.

Returns:
event data (usually phone or viseme id) associated with the end of the event

getStringData

String getStringData()
Returns any String data associated with the event (used for SAPI bookmark events).

Returns:
String data associated with the event (used for SAPI bookmark events)

getDuration

Integer getDuration()
Returns the duration of the event in milliseconds. For word boundaries, this duration for speaking the word in milliseconds. For phonemes and visemes, this is the duration of event in milliseconds.

Returns:
duration of the event in milliseconds


Copyright © 2011. All Rights Reserved.