File tree 1 file changed +0
-24
lines changed
1 file changed +0
-24
lines changed Original file line number Diff line number Diff line change @@ -38,25 +38,6 @@ export function or(...filter: IFilter[]): IFilter {
38
38
} ;
39
39
}
40
40
41
- /**
42
- * @returns A filter which combines the provided set
43
- * of filters with an and. The combines matches are
44
- * returned if *all* filters match.
45
- */
46
- export function and ( ...filter : IFilter [ ] ) : IFilter {
47
- return function ( word : string , wordToMatchAgainst : string ) : IMatch [ ] {
48
- let result : IMatch [ ] = [ ] ;
49
- for ( let i = 0 , len = filter . length ; i < len ; i ++ ) {
50
- let match = filter [ i ] ( word , wordToMatchAgainst ) ;
51
- if ( ! match ) {
52
- return null ;
53
- }
54
- result = result . concat ( match ) ;
55
- }
56
- return result ;
57
- } ;
58
- }
59
-
60
41
// Prefix
61
42
62
43
export const matchesStrictPrefix : IFilter = _matchesPrefix . bind ( undefined , false ) ;
@@ -334,11 +315,6 @@ function nextWord(word: string, start: number): number {
334
315
335
316
// Fuzzy
336
317
337
- export enum SubstringMatching {
338
- Contiguous ,
339
- Separate
340
- }
341
-
342
318
export const fuzzyContiguousFilter = or ( matchesPrefix , matchesCamelCase , matchesContiguousSubString ) ;
343
319
const fuzzySeparateFilter = or ( matchesPrefix , matchesCamelCase , matchesSubString ) ;
344
320
const fuzzyRegExpCache = new BoundedMap < RegExp > ( 10000 ) ; // bounded to 10000 elements
You can’t perform that action at this time.
0 commit comments