public static class FinderFactory.NextWordFwdFinder extends FinderFactory.GenericFwdFinder
found
Constructor and Description |
---|
NextWordFwdFinder(BaseDocument doc,
boolean stopOnEOL,
boolean stopOnWhitespace) |
Modifier and Type | Method and Description |
---|---|
void |
reset()
Reset the finder
|
protected int |
scan(char ch,
boolean lastChar)
This function decides if it found a desired string or not.
|
find
isFound
public NextWordFwdFinder(BaseDocument doc, boolean stopOnEOL, boolean stopOnWhitespace)
public void reset()
FinderFactory.AbstractFinder
reset
in interface Finder
reset
in class FinderFactory.AbstractFinder
protected int scan(char ch, boolean lastChar)
FinderFactory.GenericFwdFinder
scan
in class FinderFactory.GenericFwdFinder
found = true
and returns
how many characters back the searched string begins in forward
direction (0 stands for current character).
For example if the function looks for word 'yes' and it gets
's' as parameter it sets found = true and returns -2.
If the string is not yet found it returns how many characters it should go
in forward direction (in this case it would usually be 1).
The next searched character will be that one requested.