Examples of DFA


Examples of org.antlr.v4.runtime.dfa.DFA

  public void checkMatchedAlt(LexerGrammar lg, final Grammar g,
                String inputString,
                int expected)
  {
    ATN lexatn = createATN(lg, true);
    LexerATNSimulator lexInterp = new LexerATNSimulator(lexatn,new DFA[] { new DFA(lexatn.modeToStartState.get(Lexer.DEFAULT_MODE)) },null);
    IntegerList types = getTokenTypesViaATN(inputString, lexInterp);
    System.out.println(types);

    g.importVocab(lg);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.