Type Editor / @type-editor/search / types/QueryImpl / QueryImpl
Interface: QueryImpl
Defined in: types/QueryImpl.ts:9
Internal interface for query implementation strategies. Different implementations handle string search vs. regex search.
Methods
findNext()
ts
findNext(
state,
from,
to): SearchResult;Defined in: types/QueryImpl.ts:18
Finds the next occurrence of the query in the document.
Parameters
| Parameter | Type | Description |
|---|---|---|
state | PmEditorState | The editor state to search in |
from | number | The position to start searching from |
to | number | The position to search up to |
Returns
The search result if found, or null if no match exists
findPrev()
ts
findPrev(
state,
from,
to): SearchResult;Defined in: types/QueryImpl.ts:28
Finds the previous occurrence of the query in the document.
Parameters
| Parameter | Type | Description |
|---|---|---|
state | PmEditorState | The editor state to search in |
from | number | The position to start searching from |
to | number | The position to search back to |
Returns
The search result if found, or null if no match exists