Class TextTrieMap.LongestMatchHandler<V>

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int length  
      private java.util.Iterator<V> matches  
    • 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
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • matches

        private java.util.Iterator<V> matches
      • length

        private int length
    • Constructor Detail

      • LongestMatchHandler

        private LongestMatchHandler()
    • 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 interface TextTrieMap.ResultHandler<V>
        Parameters:
        matchLength - Matched key's length
        values - 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()