Uses of Class
org.antlr.analysis.NFAState
-
Packages that use NFAState Package Description org.antlr.analysis org.antlr.grammar.v2 org.antlr.tool -
-
Uses of NFAState in org.antlr.analysis
Fields in org.antlr.analysis declared as NFAState Modifier and Type Field Description NFAStateDFA. decisionNFAStartStateFrom what NFAState did we create the DFA?NFAStateRuleClosureTransition. followStateWhat node to begin computations following ref to ruleNFAStateNFAContext. invokingStateThe NFA state that invoked another rule's start state is recorded on the rule invocation context stack.NFAStateStateCluster. leftNFAStateStateCluster. rightFields in org.antlr.analysis with type parameters of type NFAState Modifier and Type Field Description java.util.Map<NFAState,LookaheadSet>LL1Analyzer. FIRSTCacheprotected java.util.Set<NFAState>LL1Analyzer. lookBusyUsed during LOOK to detect computation cyclesMethods in org.antlr.analysis that return NFAState Modifier and Type Method Description NFAStateDFA. getNFADecisionStartState()NFAStateNFA. getState(int s)Methods in org.antlr.analysis with parameters of type NFAState Modifier and Type Method Description protected intLL1Analyzer. _detectConfoundingPredicates(NFAState s, Rule enclosingRule, boolean chaseFollowTransitions)protected LookaheadSetLL1Analyzer. _FIRST(NFAState s, boolean chaseFollowTransitions)protected SemanticContextLL1Analyzer. _getPredicates(NFAState s, NFAState altStartState)NFAConfigurationDFAState. addNFAConfiguration(NFAState state, int alt, NFAContext context, SemanticContext semanticContext)voidDFAState. addNFAConfiguration(NFAState state, NFAConfiguration c)Add an NFA configuration to this DFA node.voidNFA. addState(NFAState state)voidNFAToDFAConverter. closure(NFAState p, int alt, NFAContext context, SemanticContext semanticContext, DFAState d, boolean collectPredicates)Where can we get from NFA state p traversing only epsilon transitions? Add new NFA states + context to DFA state d.booleanLL1Analyzer. detectConfoundingPredicates(NFAState s)Is there a non-syn-pred predicate visible from s that is not in the rule enclosing s? This accounts for most predicate situations and lets ANTLR do a simple LL(1)+pred computation.LookaheadSetLL1Analyzer. FIRST(NFAState s)From an NFA state, s, find the set of all labels reachable from s.protected booleanDecisionProbe. getNFAPath(NFAState s, int labelIndex, java.util.List labels, java.util.List path)Given a sample input sequence, you usually would like to know the path taken through the NFA.SemanticContextLL1Analyzer. getPredicates(NFAState altStartState)Return predicate expression found via epsilon edges from s.protected SemanticContext.PredicateLL1DFA. getSynPredForAlt(NFAState decisionStartState, int alt)LookaheadSetLL1Analyzer. LOOK(NFAState s)Constructors in org.antlr.analysis with parameters of type NFAState Constructor Description DFA(int decisionNumber, NFAState decisionStartState)LL1DFA(int decisionNumber, NFAState decisionStartState, LookaheadSet[] altLook)From list of lookahead sets (one per alt in decision), create an LL(1) DFA.LL1DFA(int decisionNumber, NFAState decisionStartState, MultiMap<IntervalSet,java.lang.Integer> edgeMap)From a set of edgeset->list-of-alts mappings, create a DFA that uses syn preds for all |list-of-alts|>1.NFAContext(NFAContext parent, NFAState invokingState)RuleClosureTransition(Rule rule, NFAState ruleStart, NFAState followState)StateCluster(NFAState left, NFAState right) -
Uses of NFAState in org.antlr.grammar.v2
Methods in org.antlr.grammar.v2 with parameters of type NFAState Modifier and Type Method Description protected voidTreeToNFAConverter. addFollowTransition(java.lang.String ruleName, NFAState following) -
Uses of NFAState in org.antlr.tool
Fields in org.antlr.tool declared as NFAState Modifier and Type Field Description NFAStateGrammarAST. followingNFAStateRule ref nodes, token refs, set, and NOT set refs need to track their location in the generated NFA so that local FOLLOW sets can be computed during code gen for automatic error recovery.NFAStateGrammarAST. NFAStartStateWhat NFA start state was built from this node?NFAStateGrammarAST. NFATreeDownStateThis is used for TREE_BEGIN nodes to point into the NFA.NFAStateGrammar.Decision. startStateNFAStateRule. startStateNFAStateRule. stopStateFields in org.antlr.tool with type parameters of type NFAState Modifier and Type Field Description protected java.util.Vector<NFAState>CompositeGrammar. numberToStateListThe NFA states in the NFA built from rules across grammars in composite.protected java.util.Set<NFAState>CompositeGrammar. refClosureBusyUsed during getRuleReferenceClosure to detect computation cyclesMethods in org.antlr.tool that return NFAState Modifier and Type Method Description NFAStateGrammar. getDecisionNFAStartState(int decision)NFAStateGrammarAST. getNFAStartState()NFAStateGrammar. getNFAStateForAltOfDecision(NFAState decisionState, int alt)Get the ith alternative (1..n) from a decision; return null when an invalid alt is requested.NFAStateGrammar. getRuleStartState(java.lang.String ruleName)NFAStateGrammar. getRuleStartState(java.lang.String scopeName, java.lang.String ruleName)NFAStateGrammar. getRuleStopState(java.lang.String ruleName)NFAStateCompositeGrammar. getState(int s)NFAStateNFAFactory. newState()Methods in org.antlr.tool with parameters of type NFAState Modifier and Type Method Description voidCompositeGrammar. addState(NFAState state)intGrammar. assignDecisionNumber(NFAState state)private voidNFAFactory. build_EOFState(NFAState endNFAState)set up an NFA NFAState that will yield eof tokens or, in the case of a lexer grammar, an EOT token when the conversion hits the end of a rule.StateClusterNFAFactory. build_RuleRef(Rule refDef, NFAState ruleStart)For reference to rule r, build o-e->(r) o where (r) is the start of rule r and the trailing o is not linked to from rule ref state directly (it's done thru the transition(0) RuleClosureTransition.LookaheadSetGrammar. FIRST(NFAState s)NFAStateGrammar. getNFAStateForAltOfDecision(NFAState decisionState, int alt)Get the ith alternative (1..n) from a decision; return null when an invalid alt is requested.intGrammar. getNumberOfAltsForDecisionNFA(NFAState decisionState)Decisions are linked together with transition(1).LookaheadSetGrammar. LOOK(NFAState s)protected voidInterpreter. parseEngine(java.lang.String startRule, NFAState start, NFAState stop, IntStream input, java.util.Stack ruleInvocationStack, DebugEventListener actions, java.util.List visitedStates)Fill a list of all NFA states visited during the parsevoidGrammar. setDecisionNFA(int decision, NFAState state)voidGrammarAST. setNFAStartState(NFAState nfaStartState)protected booleanGrammarSanity. traceStatesLookingForLeftRecursion(NFAState s, java.util.Set visitedStates, java.util.List<java.util.Set<Rule>> listOfRecursiveCycles)From state s, look for any transition to a rule that is currently being traced.private voidNFAFactory. transitionBetweenStates(NFAState a, NFAState b, int label)
-