LEFT | RIGHT |
1 /* | 1 /* |
2 * This file is part of Adblock Plus <https://adblockplus.org/>, | 2 * This file is part of Adblock Plus <https://adblockplus.org/>, |
3 * Copyright (C) 2006-present eyeo GmbH | 3 * Copyright (C) 2006-present eyeo GmbH |
4 * | 4 * |
5 * Adblock Plus is free software: you can redistribute it and/or modify | 5 * Adblock Plus is free software: you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 3 as | 6 * it under the terms of the GNU General Public License version 3 as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
8 * | 8 * |
9 * Adblock Plus is distributed in the hope that it will be useful, | 9 * Adblock Plus is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
295 * Checks whether the entries for a particular keyword match a URL | 295 * Checks whether the entries for a particular keyword match a URL |
296 * @param {string} keyword | 296 * @param {string} keyword |
297 * @param {string} location | 297 * @param {string} location |
298 * @param {number} typeMask | 298 * @param {number} typeMask |
299 * @param {string} [docDomain] | 299 * @param {string} [docDomain] |
300 * @param {boolean} [thirdParty] | 300 * @param {boolean} [thirdParty] |
301 * @param {string} [sitekey] | 301 * @param {string} [sitekey] |
302 * @param {boolean} [specificOnly] | 302 * @param {boolean} [specificOnly] |
303 * @param {?Array.<Filter>} [collection] An optional list of filters to which | 303 * @param {?Array.<Filter>} [collection] An optional list of filters to which |
304 * to append any results. If specified, the function adds <em>all</em> | 304 * to append any results. If specified, the function adds <em>all</em> |
305 * matching filters to the list; if ommitted, the function directly returns | 305 * matching filters to the list; if omitted, the function directly returns |
306 * the first matching filter. | 306 * the first matching filter. |
307 * @returns {?Filter} | 307 * @returns {?Filter} |
308 * @protected | 308 * @protected |
309 */ | 309 */ |
310 checkEntryMatch(keyword, location, typeMask, docDomain, thirdParty, sitekey, | 310 checkEntryMatch(keyword, location, typeMask, docDomain, thirdParty, sitekey, |
311 specificOnly, collection) | 311 specificOnly, collection) |
312 { | 312 { |
313 // We need to skip the simple (location-only) filters if the type mask does | 313 // We need to skip the simple (location-only) filters if the type mask does |
314 // not contain any default content types. | 314 // not contain any default content types. |
315 if ((typeMask & DEFAULT_TYPES) != 0) | 315 if ((typeMask & DEFAULT_TYPES) != 0) |
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
674 | 674 |
675 exports.CombinedMatcher = CombinedMatcher; | 675 exports.CombinedMatcher = CombinedMatcher; |
676 | 676 |
677 /** | 677 /** |
678 * Shared {@link CombinedMatcher} instance that should usually be used. | 678 * Shared {@link CombinedMatcher} instance that should usually be used. |
679 * @type {CombinedMatcher} | 679 * @type {CombinedMatcher} |
680 */ | 680 */ |
681 let defaultMatcher = new CombinedMatcher(); | 681 let defaultMatcher = new CombinedMatcher(); |
682 | 682 |
683 exports.defaultMatcher = defaultMatcher; | 683 exports.defaultMatcher = defaultMatcher; |
LEFT | RIGHT |