|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CharSequenceMatcher
Implementations of this interface will provide the logic for searching in the
given CharSequence
. The
findMatches(CharSequence, MatchConsumer)
method will be called
during the AbstractCharSequenceSearchRequest
processing.
Method Summary | |
---|---|
void |
cancel()
Tells the CharSequenceMatcher that the current
search request has been canceled (
AbstractCharSequenceSearchRequest.cancel() .The findMatches(CharSequence, MatchConsumer) implementation has to take care that the
search loop will be stopped and that the method returns as fast as possible. |
void |
findMatches(CharSequence charSequence,
MatchConsumer matchConsumer)
Runs the search for some sequence of characters. |
Method Detail |
---|
void findMatches(CharSequence charSequence, MatchConsumer matchConsumer)
Runs the search for some sequence of characters. Implementations are free
to decide how to search for matches in the given CharSequence
.
Results found have to be provided to the
MatchConsumer.match(int, int)
or
MatchConsumer.match(int, int, Object)
methods.
IMPORTANT: If the cancel()
method has been called, the
implementation of this method has to take care of shutting down as soon as
possible.
charSequence
- the source textmatchConsumer
- the MatchConsumer
which will get notified
about any matches found.void cancel()
CharSequenceMatcher
that the current
search request
has been canceled (
AbstractCharSequenceSearchRequest.cancel()
.findMatches(CharSequence, MatchConsumer)
implementation has to take care that the
search loop will be stopped and that the method returns as fast as possible.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |