Class FlagEnumerator
- java.lang.Object
-
- org.apache.lucene.analysis.hunspell.FlagEnumerator
-
class FlagEnumerator extends java.lang.Object
A structure similar toBytesRefHash
, but specialized for sorted char sequences used for Hunspell flags. It deduplicates flag sequences, gives them unique ids, stores the sequences in a contiguous char[] (viafinish()
and allows to query presence of the flags later viaFlagEnumerator.Lookup.hasFlag(int, char)
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
FlagEnumerator.Lookup
-
Constructor Summary
Constructors Constructor Description FlagEnumerator()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) int
add(char[] chars)
(package private) FlagEnumerator.Lookup
finish()
(package private) static boolean
hasFlagInSortedArray(char flag, char[] array, int start, int length)
-
-
-
Method Detail
-
add
int add(char[] chars)
-
finish
FlagEnumerator.Lookup finish()
-
hasFlagInSortedArray
static boolean hasFlagInSortedArray(char flag, char[] array, int start, int length)
-
-