SpeakableSsmlText implements SpeakableText { public SpeakableText appendSpeakableText(final String str) { if (document == null) { return this; } final Speak speak = document.getSpeak(); speak.addText(str); return this; } SpeakableSsmlText(final String text, final Locale locale);  SpeakableSsmlText(final SsmlDocument doc);  SpeakableSsmlText(final SsmlDocument doc, final boolean useBargein,
            final BargeInType type); String getSpeakableText(); SsmlDocument getDocument(); SpeakableText appendSpeakableText(final String str); boolean isSpeakableTextEmpty(); @Override boolean isBargeInEnabled(final BargeInType type); BargeInType getBargeInType(); long getTimeout(); void setTimeout(final long msec); @Override boolean equals(final Object other); @Override int hashCode(); @Override String toString();  }
@Test public void testAppendSpeakableText() throws Exception { final SsmlDocument doc = new SsmlDocument(); final SpeakableSsmlText speakable = new SpeakableSsmlText(doc); Assert.assertTrue(speakable.isSpeakableTextEmpty()); speakable.appendSpeakableText("some"); final Speak speak = doc.getSpeak(); Assert.assertEquals("some", speak.getTextContent()); speakable.appendSpeakableText(" text"); Assert.assertEquals("some text", speak.getTextContent()); }