edu.cmu.sphinx.linguist.language.grammar
Class GrammarArc

java.lang.Object
  extended byedu.cmu.sphinx.linguist.language.grammar.GrammarArc

public class GrammarArc
extends java.lang.Object

Represents a single transition out of a grammar node. The grammar represented is a stochastic grammar, each transition has a probability associated with it. The probabilities are relative and are not necessarily constrained to total 1.0. Note that all probabilities are maintained in the LogMath log base


Constructor Summary
GrammarArc(GrammarNode grammarNode, float logProbability)
          Create a grammar arc
 
Method Summary
 GrammarNode getGrammarNode()
          Retrieves the destination node for this transition
 float getProbability()
          Retrieves the probability for this transition
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GrammarArc

public GrammarArc(GrammarNode grammarNode,
                  float logProbability)
Create a grammar arc

Parameters:
grammarNode - the node that this arc points to
logProbability - the log probability of following this arc
Method Detail

getGrammarNode

public GrammarNode getGrammarNode()
Retrieves the destination node for this transition

Returns:
the destination node

getProbability

public float getProbability()
Retrieves the probability for this transition

Returns:
the log probability for this transition