mirror of https://github.com/gorhill/uBlock.git
Output highly generic cosmetic filters
This commit is contained in:
parent
426bf2d170
commit
10e680c2ef
|
@ -965,16 +965,22 @@ FilterContainer.prototype.getFilterCount = function() {
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
||||||
FilterContainer.prototype.dump = function() {
|
FilterContainer.prototype.dump = function() {
|
||||||
const generics = [];
|
const lowlyGenerics = [];
|
||||||
for ( const selectors of this.lowlyGeneric.values() ) {
|
for ( const selectors of this.lowlyGeneric.values() ) {
|
||||||
generics.push(...selectors.split(',\n'));
|
lowlyGenerics.push(...selectors.split(',\n'));
|
||||||
}
|
}
|
||||||
|
lowlyGenerics.sort();
|
||||||
|
const highlyGenerics = Array.from(this.highlyGeneric.simple.dict);
|
||||||
|
highlyGenerics.push(Array.from(this.highlyGeneric.complex.dict));
|
||||||
|
highlyGenerics.sort();
|
||||||
return [
|
return [
|
||||||
'Cosmetic Filtering Engine internals:',
|
'Cosmetic Filtering Engine internals:',
|
||||||
`specific: ${this.specificFilters.size}`,
|
`specific: ${this.specificFilters.size}`,
|
||||||
`generic: ${generics.length}`,
|
`generic: ${lowlyGenerics.length + highlyGenerics.length}`,
|
||||||
`+ selectors: ${this.lowlyGeneric.size}`,
|
`+ lowly generic: ${lowlyGenerics.length}`,
|
||||||
...generics.map(a => ` ${a}`),
|
...lowlyGenerics.map(a => ` ${a}`),
|
||||||
|
`+ highly generic: ${highlyGenerics.length}`,
|
||||||
|
...highlyGenerics.map(a => ` ${a}`),
|
||||||
].join('\n');
|
].join('\n');
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue