1
>
/*---------------------------------------------------------------------------------------------
textModelSearch.ts
2
>
* Copyright (c) Microsoft Corporation. All rights reserved.
3
>
* Licensed under the MIT License. See License.txt in the project root for license information.
4
>
*--------------------------------------------------------------------------------------------*/
5
>
6
>
import { CharCode } from '../../../base/common/charCode.js';
7
>
import * as strings from '../../../base/common/strings.js';
8
>
import { WordCharacterClass, WordCharacterClassifier, getMapForWordSeparators } from '../core/wordCharacterClassifier.js';
9
>
import { Position } from '../core/position.js';
10
>
import { Range } from '../core/range.js';
11
>
import { EndOfLinePreference, FindMatch, SearchData } from '../model.js';
12
>
import { TextModel } from './textModel.js';
13
>
14
>
const LIMIT_FIND_COUNT = 999;
15
>
16
>
export class SearchParams {
17
>
public readonly searchString: string;
18
>
public readonly isRegex: boolean;
19
>
public readonly matchCase: boolean;
20
>
public readonly wordSeparators: string | null;
21
>
22
>
constructor(searchString: string, isRegex: boolean, matchCase: boolean, wordSeparators: string | null) {
23
this.searchString = searchString;
24
this.isRegex = isRegex;