public class SearchTree<T> extends java.lang.Object implements ISearchTree<T>
Modifier and Type | Field and Description |
---|---|
protected SuffixArray<T> |
byId |
protected SuffixArray<T> |
byName |
Constructor and Description |
---|
SearchTree(java.util.function.Function<T,java.lang.Iterable<java.lang.String>> nameFuncIn,
java.util.function.Function<T,java.lang.Iterable<ResourceLocation>> idFuncIn) |
Modifier and Type | Method and Description |
---|---|
void |
add(T element) |
void |
recalculate() |
java.util.List<T> |
search(java.lang.String searchText) |
protected SuffixArray<T> byId
protected SuffixArray<T> byName
public SearchTree(java.util.function.Function<T,java.lang.Iterable<java.lang.String>> nameFuncIn, java.util.function.Function<T,java.lang.Iterable<ResourceLocation>> idFuncIn)
public void recalculate()
public void add(T element)
public java.util.List<T> search(java.lang.String searchText)
search
in interface ISearchTree<T>