Package com.ibm.icu.impl
Class TextTrieMap.LongestMatchHandler<V>
- java.lang.Object
-
- com.ibm.icu.impl.TextTrieMap.LongestMatchHandler<V>
-
- All Implemented Interfaces:
TextTrieMap.ResultHandler<V>
- Enclosing class:
- TextTrieMap<V>
private static class TextTrieMap.LongestMatchHandler<V> extends java.lang.Object implements TextTrieMap.ResultHandler<V>
-
-
Constructor Summary
Constructors Modifier Constructor Description private
LongestMatchHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Iterator<V>
getMatches()
int
getMatchLength()
boolean
handlePrefixMatch(int matchLength, java.util.Iterator<V> values)
Handles a prefix key match
-
-
-
Field Detail
-
matches
private java.util.Iterator<V> matches
-
length
private int length
-
-
Method Detail
-
handlePrefixMatch
public boolean handlePrefixMatch(int matchLength, java.util.Iterator<V> values)
Description copied from interface:TextTrieMap.ResultHandler
Handles a prefix key match- Specified by:
handlePrefixMatch
in interfaceTextTrieMap.ResultHandler<V>
- Parameters:
matchLength
- Matched key's lengthvalues
- An iterator of the objects associated with the matched key- Returns:
- Return true to continue the search in the trie, false to quit.
-
getMatches
public java.util.Iterator<V> getMatches()
-
getMatchLength
public int getMatchLength()
-
-