Class TextSynthesizerQueueItem

java.lang.Object
SynthesizerQueueItem
com.sun.speech.engine.synthesis.BaseSynthesizerQueueItem
com.sun.speech.engine.synthesis.text.TextSynthesizerQueueItem
All Implemented Interfaces:
SpeechEventDispatcher

public class TextSynthesizerQueueItem extends BaseSynthesizerQueueItem
Represents an object on the speech output queue of a TextSynthesizer.
  • Field Details

  • Constructor Details

    • TextSynthesizerQueueItem

      public TextSynthesizerQueueItem()
      Class constructor.
  • Method Details

    • getTypeString

      public String getTypeString()
      Gets the type of this queue item.
      Returns:
      a String for debug purposes
    • linearize

      protected void linearize(Node n, StringBuffer buf)
      Appends the text for this node to the given StringBuffer.
      Parameters:
      n - the node to traverse in depth-first order
      buf - the buffer to append text to
    • processNode

      protected StringBuffer processNode(Node n, StringBuffer buf)
      Adds text for just this node, and returns any text that might be needed to undo the effects of this node after it is processed.
      Parameters:
      n - the node to traverse in depth-first order
      buf - the buffer to append text to
      Returns:
      a String containing text to undo the effects of the node
    • processElement

      protected StringBuffer processElement(Element element, StringBuffer buf)
      Adds any commands for this element and returns any text that might be needed to undo the effects of this element after it is processed.
      Parameters:
      element - the element to traverse in depth-first order
      buf - the buffer to append text to
      Returns:
      a String containing text to undo the effects of the element
    • processAttributes

      protected StringBuffer processAttributes(Element element, String[] attributes)
      Gets the list of attributes of the element and returns them in a StringBuffer.
      Parameters:
      element - the element containing attributes (if any)
      attributes - the allowed attributes for element
      Returns:
      a buffer containing the attributes in text form
    • getEngineText

      public String getEngineText()
      Gets the text form of this queue item.
      Returns:
      the text form of this queue item.