edu.cmu.sphinx.linguist.flat
Class PronunciationState

java.lang.Object
  extended byedu.cmu.sphinx.linguist.flat.SentenceHMMState
      extended byedu.cmu.sphinx.linguist.flat.PronunciationState
All Implemented Interfaces:
SearchState, java.io.Serializable, WordSearchState

public class PronunciationState
extends SentenceHMMState
implements WordSearchState

Represents a pronunciation in an SentenceHMMS

See Also:
Serialized Form

Constructor Summary
PronunciationState(java.lang.String name, Pronunciation p, int which)
          Creates a PronunciationState
PronunciationState(WordState parent, int which)
          Creates a PronunciationState
 
Method Summary
 int getOrder()
          Returns the state order for this state type
 Pronunciation getPronunciation()
          Gets the pronunciation associated with this state
 java.lang.String getTypeLabel()
          Retrieves a short label describing the type of this state.
 boolean isWordStart()
          Returns true if this PronunciationState indicates the start of a word.
 
Methods inherited from class edu.cmu.sphinx.linguist.flat.SentenceHMMState
collectStates, connect, dumpAll, findArc, getAssociatedWord, getColor, getFullName, getLexState, getName, getNumSuccessors, getParent, getPrettyName, getSignature, getSuccessors, getTitle, getValueSignature, getWhich, getWordHistory, isEmitting, isFanIn, isFinal, isProcessed, isSharedState, isUnit, resetAllProcessed, setColor, setFanIn, setFinalState, setProcessed, setSharedState, setWhich, setWordStart, toPrettyString, toString, validateAll, visitStates
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface edu.cmu.sphinx.linguist.SearchState
getLexState, getSignature, getSuccessors, getWordHistory, isEmitting, isFinal, toPrettyString
 

Constructor Detail

PronunciationState

public PronunciationState(WordState parent,
                          int which)
Creates a PronunciationState

Parameters:
parent - the parent word of the current pronunciation
which - the pronunciation of interest

PronunciationState

public PronunciationState(java.lang.String name,
                          Pronunciation p,
                          int which)
Creates a PronunciationState

Parameters:
name - the name of the pronunciation associated with this state
p - the pronunciation
which - the index for the pronunciation
Method Detail

getPronunciation

public Pronunciation getPronunciation()
Gets the pronunciation associated with this state

Specified by:
getPronunciation in interface WordSearchState
Returns:
the pronunciation

getTypeLabel

public java.lang.String getTypeLabel()
Retrieves a short label describing the type of this state. Typically, subclasses of SentenceHMMState will implement this method and return a short (5 chars or less) label

Overrides:
getTypeLabel in class SentenceHMMState
Returns:
the short label.

getOrder

public int getOrder()
Returns the state order for this state type

Specified by:
getOrder in interface SearchState
Specified by:
getOrder in class SentenceHMMState
Returns:
the state order

isWordStart

public boolean isWordStart()
Returns true if this PronunciationState indicates the start of a word. Returns false if this PronunciationState indicates the end of a word.

Specified by:
isWordStart in interface WordSearchState
Overrides:
isWordStart in class SentenceHMMState
Returns:
true if this PronunciationState indicates the start of a word, false if this PronunciationState indicates the end of a word