Package org.apache.lucene.util.automaton
Class CompiledAutomaton
java.lang.Object
org.apache.lucene.util.automaton.CompiledAutomaton
Immutable class holding compiled details for a given
Automaton. The Automaton is deterministic, must not have
dead states but is not necessarily minimal.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumAutomata are compiled into different internal forms for the most efficient execution depending upon the language they accept. -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal BytesRefShared common suffix accepted by the automaton.final BooleanIndicates if the automaton accepts a finite set of strings.final ByteRunAutomatonMatcher for quickly determining if a byte[] is accepted.final Transition[][]Two dimensional array of transitions, indexed by state number for traversal.final BytesRefForCompiledAutomaton.AUTOMATON_TYPE.PREFIX, this is the prefix term; forCompiledAutomaton.AUTOMATON_TYPE.SINGLEthis is the singleton term. -
Constructor Summary
ConstructorsConstructorDescriptionCompiledAutomaton(Automaton automaton) CompiledAutomaton(Automaton automaton, Boolean finite, boolean simplify) -
Method Summary
-
Field Details
-
type
-
term
ForCompiledAutomaton.AUTOMATON_TYPE.PREFIX, this is the prefix term; forCompiledAutomaton.AUTOMATON_TYPE.SINGLEthis is the singleton term. -
runAutomaton
Matcher for quickly determining if a byte[] is accepted. only valid forCompiledAutomaton.AUTOMATON_TYPE.NORMAL. -
sortedTransitions
Two dimensional array of transitions, indexed by state number for traversal. The state numbering is consistent withrunAutomaton. Only valid forCompiledAutomaton.AUTOMATON_TYPE.NORMAL. -
commonSuffixRef
Shared common suffix accepted by the automaton. Only valid forCompiledAutomaton.AUTOMATON_TYPE.NORMAL, and only when the automaton accepts an infinite language. -
finite
Indicates if the automaton accepts a finite set of strings. Null if this was not computed. Only valid forCompiledAutomaton.AUTOMATON_TYPE.NORMAL.
-
-
Constructor Details
-
CompiledAutomaton
-
CompiledAutomaton
-
-
Method Details
-
getTermsEnum
- Throws:
IOException
-
floor
Finds largest term accepted by this Automaton, that's invalid input: '<'= the provided input term. The result is placed in output; it's fine for output and input to point to the same BytesRef. The returned result is either the provided output, or null if there is no floor term (ie, the provided input term is before the first term accepted by this Automaton). -
toDot
-
hashCode
public int hashCode() -
equals
-