Class CharTrieOfOne
java.lang.Object
ch.randelshofer.fastdoubleparser.chr.CharTrieOfOne
- All Implemented Interfaces:
CharTrie
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintmatch(char[] str) Searches for the longest matching string in the trie that matches the provided string.intmatch(char[] str, int startIndex, int endIndex) Searches for the longest matching string in the trie that matches the provided string.intmatch(CharSequence str) Searches for the longest matching string in the trie that matches the provided string.intmatch(CharSequence str, int startIndex, int endIndex) Searches for the longest matching string in the trie that matches the provided string.
-
Field Details
-
chars
private final char[] chars
-
-
Constructor Details
-
CharTrieOfOne
-
CharTrieOfOne
public CharTrieOfOne(char[] chars)
-
-
Method Details
-
match
Description copied from interface:CharTrieSearches for the longest matching string in the trie that matches the provided string.- Specified by:
matchin interfaceCharTrie- Parameters:
str- a string in the form of aCharSequence- Returns:
- the length of the longest matching string, or 0 if no string matches
-
match
Description copied from interface:CharTrieSearches for the longest matching string in the trie that matches the provided string. -
match
public int match(char[] str) Description copied from interface:CharTrieSearches for the longest matching string in the trie that matches the provided string. -
match
public int match(char[] str, int startIndex, int endIndex) Description copied from interface:CharTrieSearches for the longest matching string in the trie that matches the provided string.
-