Package org.nineml.coffeegrinder.util
Class BricsAmbiguity
- java.lang.Object
-
- org.nineml.coffeegrinder.util.BricsAmbiguity
-
public class BricsAmbiguity extends java.lang.ObjectUse the Brics ambiguity analyzer.
-
-
Constructor Summary
Constructors Constructor Description BricsAmbiguity()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckGrammar(Grammar grammar, NonterminalSymbol seed, java.io.PrintWriter report)Check the grammar for ambiguity.dk.brics.automaton.AutomatongetAutomaton(java.lang.String charClass)Get the automaton for checkig a character class.booleangetCheckSucceeded()Did the attempt to analyze ambiguity succeed?booleangetReliable()Is the report reliable?booleangetUnambiguous()Is the grammar unambiguous?
-
-
-
Method Detail
-
getReliable
public boolean getReliable()
Is the report reliable?- Returns:
- true if it is.
-
getUnambiguous
public boolean getUnambiguous()
Is the grammar unambiguous?- Returns:
- true if it is.
-
getCheckSucceeded
public boolean getCheckSucceeded()
Did the attempt to analyze ambiguity succeed?- Returns:
- true if it did.
-
checkGrammar
public void checkGrammar(Grammar grammar, NonterminalSymbol seed, java.io.PrintWriter report)
Check the grammar for ambiguity.- Parameters:
grammar- the grammar.seed- the seed.report- Where to write the ambiguity report.
-
getAutomaton
public dk.brics.automaton.Automaton getAutomaton(java.lang.String charClass)
Get the automaton for checkig a character class.- Parameters:
charClass- the class.- Returns:
- the automaton.
-
-