FastIntSequenceSearch instead@Deprecated
public class FastSequentialSearch
extends java.lang.Object
Currently only forward search is implemented.
Although based on integers this may also be used for searches in byte or character sequences.
| Constructor and Description |
|---|
FastSequentialSearch(IntIndexable searchTerm)
Deprecated.
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
IntIndexable |
findAllMatches(IntIndexable data,
boolean allowOverlaps)
Deprecated.
|
int |
findFirst(IntIndexable data)
Deprecated.
Find the first appearance of the search term in the given data.
|
int |
findNext(IntIndexable data,
int pos)
Deprecated.
Find the next appearance of the search term after the given position
in the given data.
|
int |
findNext(IntIndexable data,
int pos,
int end)
Deprecated.
Find the next appearance of the search term after the given start position
and before the given end position in the given data.
|
public FastSequentialSearch(@NotNull IntIndexable searchTerm)
searchTerm - term to search forpublic int findFirst(@NotNull IntIndexable data)
data - data to search through-1 if there was nothing foundpublic int findNext(@NotNull IntIndexable data, int pos)
data - data to search throughpos - position to start the search-1 if there was nothing found between the position and the end of datapublic int findNext(@NotNull IntIndexable data, int pos, int end)
data - data to search throughpos - position to start the searchend - position to end the search, the whole search term has to fit before this position to be found-1 if there was nothing found between the position and the end of data@NotNull public IntIndexable findAllMatches(@NotNull IntIndexable data, boolean allowOverlaps)