Package apple.uikit.protocol
Interface UITextSearchAggregator
-
public interface UITextSearchAggregatorAPI-Since: 16.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description @NotNull NSOrderedSet<? extends UITextRange>allFoundRanges()Returns all currently reported found ranges via @c foundRange:forSearchString:.voidfinishedSearching()Call this method after all documents have been searched.voidfoundRangeForSearchStringInDocument(@NotNull UITextRange range, @NotNull java.lang.String string, @Nullable java.lang.Object document)Call this method when a range of text is found in your document.voidinvalidate()Call this method to invalidate all currently shown ranges.voidinvalidateFoundRangeInDocument(@NotNull UITextRange range, @Nullable java.lang.Object document)Call this method when a found @c range is no longer in @c document .
-
-
-
Method Detail
-
allFoundRanges
@NotNull @NotNull NSOrderedSet<? extends UITextRange> allFoundRanges()
Returns all currently reported found ranges via @c foundRange:forSearchString:.
-
finishedSearching
void finishedSearching()
Call this method after all documents have been searched.
-
foundRangeForSearchStringInDocument
void foundRangeForSearchStringInDocument(@NotNull @NotNull UITextRange range, @NotNull @NotNull java.lang.String string, @Nullable @Nullable java.lang.Object document)Call this method when a range of text is found in your document.- Parameters:
range- The range of text that was found.string- The query string that was used to locate this range of text.document- (Optional) A developer-defined document identifier, later provided when this range needs to be styled.
-
invalidate
void invalidate()
Call this method to invalidate all currently shown ranges. This will cause the system find panel to update it's current state, and may trigger a new search using `performTextSearchWithQueryString:` immediately after.
-
invalidateFoundRangeInDocument
void invalidateFoundRangeInDocument(@NotNull @NotNull UITextRange range, @Nullable @Nullable java.lang.Object document)Call this method when a found @c range is no longer in @c document . This will cause the system find panel to update it's current state, and if the range provided is the currently highlighted range, will advance to the next found result.- Parameters:
range- The range that is now invalid.document- (Optional) If multiple documents are used, the document identifier for the range provided.
-
-