Class Hypothesis
- java.lang.Object
-
- ai.rev.speechtotext.models.streaming.StreamingResponseMessage
-
- ai.rev.speechtotext.models.streaming.Hypothesis
-
public class Hypothesis extends StreamingResponseMessage
Represents the message returned over WebSocket containing the transcription of audio data.
-
-
Constructor Summary
Constructors Constructor Description Hypothesis()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Element[]getElements()Returns a list ofElementobjects.DoublegetEndTs()Returns the ending timestamp of a transcribed audio sample.DoublegetTs()Returns the starting timestamp of a transcribed audio sample.voidsetElements(Element[] elements)Sets elements to the list ofElementobjects provided.voidsetEndTs(Double endTs)Sets the ending timestamp.voidsetTs(Double ts)Sets the starting timestamp.StringtoString()-
Methods inherited from class ai.rev.speechtotext.models.streaming.StreamingResponseMessage
getType, setType
-
-
-
-
Method Detail
-
getTs
public Double getTs()
Returns the starting timestamp of a transcribed audio sample.- Returns:
- The starting timestamp of a transcribed audio sample.
-
setTs
public void setTs(Double ts)
Sets the starting timestamp.- Parameters:
ts- The starting timestamp.
-
getEndTs
public Double getEndTs()
Returns the ending timestamp of a transcribed audio sample.- Returns:
- The ending timestamp of a transcribed audio sample.
-
setEndTs
public void setEndTs(Double endTs)
Sets the ending timestamp.- Parameters:
endTs- The ending timestamp.
-
setElements
public void setElements(Element[] elements)
Sets elements to the list ofElementobjects provided.
-
toString
public String toString()
- Overrides:
toStringin classStreamingResponseMessage
-
-