| Left: | ||
| Right: |
| 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-2015 Eyeo GmbH | 3 * Copyright (C) 2006-2015 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 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 293 * using `ReferrerMapping`. | 293 * using `ReferrerMapping`. |
| 294 * @return Matching filter, or a `null` if there was no match. | 294 * @return Matching filter, or a `null` if there was no match. |
| 295 * @throw `std::invalid_argument`, if an invalid `contentType` was supplied. | 295 * @throw `std::invalid_argument`, if an invalid `contentType` was supplied. |
| 296 */ | 296 */ |
| 297 FilterPtr Matches(const std::string& url, | 297 FilterPtr Matches(const std::string& url, |
| 298 ContentType contentType, | 298 ContentType contentType, |
| 299 const std::vector<std::string>& documentUrls) const; | 299 const std::vector<std::string>& documentUrls) const; |
| 300 | 300 |
| 301 /** | 301 /** |
| 302 * Checks whether the document at the supplied URL is whitelisted. | 302 * Checks whether the document at the supplied URL is whitelisted. |
| 303 * @param url URL of the document | 303 * @param url URL of the document. |
|
Felix Dahlke
2015/12/02 18:02:01
Nit: Seems we usually end with a period.
René Jeschke
2015/12/02 18:09:41
Done.
| |
| 304 * @param documentUrls Chain of document URLs requesting the document, | 304 * @param documentUrls Chain of document URLs requesting the document, |
| 305 * starting with the current documents's parent frame, ending with | 305 * starting with the current document's parent frame, ending with |
|
Felix Dahlke
2015/12/02 18:02:02
Typo: s/documents's/document's/
René Jeschke
2015/12/02 18:09:41
Done.
| |
| 306 * the top-level frame. | 306 * the top-level frame. |
| 307 * If the application is not capable of identifying the frame | 307 * If the application is not capable of identifying the frame |
| 308 * structure, e.g. because it is a proxy, it can be approximated | 308 * structure, e.g. because it is a proxy, it can be approximated |
| 309 * using `ReferrerMapping`. | 309 * using `ReferrerMapping`. |
| 310 * @return `true` if the URL is whitelisted. | 310 * @return `true` if the URL is whitelisted. |
| 311 */ | 311 */ |
| 312 bool IsDocumentWhitelisted(const std::string& url, | 312 bool IsDocumentWhitelisted(const std::string& url, |
| 313 const std::vector<std::string>& documentUrls) const; | 313 const std::vector<std::string>& documentUrls) const; |
| 314 | 314 |
| 315 /** | 315 /** |
| 316 * Checks whether element hiding is disabled at the supplied URL. | 316 * Checks whether element hiding is disabled at the supplied URL. |
| 317 * @param url URL to match. | 317 * @param url URL of the document. |
|
Felix Dahlke
2015/12/02 18:01:58
Maybe it's not entirely correct, but I think it'd
René Jeschke
2015/12/02 18:09:41
Done.
| |
| 318 * @param documentUrls Chain of documents requesting the resource, starting | 318 * @param documentUrls Chain of document URLs requesting the document, |
|
Felix Dahlke
2015/12/02 18:02:01
Same as above, we're not really talking about a "r
René Jeschke
2015/12/02 18:09:42
Done.
| |
| 319 * with the current resource's parent frame, ending with the | 319 * starting with the current document's parent frame, ending with |
| 320 * top-level frame. | 320 * the top-level frame. |
| 321 * If the application is not capable of identifying the frame | 321 * If the application is not capable of identifying the frame |
| 322 * structure, e.g. because it is a proxy, it can be approximated | 322 * structure, e.g. because it is a proxy, it can be approximated |
| 323 * using `ReferrerMapping`. | 323 * using `ReferrerMapping`. |
| 324 * @return `true` if element hiding is whitelisted for the supplied URL. | 324 * @return `true` if element hiding is whitelisted for the supplied URL. |
| 325 */ | 325 */ |
| 326 bool IsElemhideWhitelisted(const std::string& url, | 326 bool IsElemhideWhitelisted(const std::string& url, |
| 327 const std::vector<std::string>& documentUrls) const; | 327 const std::vector<std::string>& documentUrls) const; |
| 328 | 328 |
| 329 /** | 329 /** |
| 330 * Retrieves CSS selectors for all element hiding filters active on the | 330 * Retrieves CSS selectors for all element hiding filters active on the |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 439 const JsValueList& params); | 439 const JsValueList& params); |
| 440 FilterPtr GetWhitelistingFilter(const std::string& url, | 440 FilterPtr GetWhitelistingFilter(const std::string& url, |
| 441 ContentType contentType, const std::string& documentUrl) const; | 441 ContentType contentType, const std::string& documentUrl) const; |
| 442 FilterPtr GetWhitelistingFilter(const std::string& url, | 442 FilterPtr GetWhitelistingFilter(const std::string& url, |
| 443 ContentType contentType, | 443 ContentType contentType, |
| 444 const std::vector<std::string>& documentUrls) const; | 444 const std::vector<std::string>& documentUrls) const; |
| 445 }; | 445 }; |
| 446 } | 446 } |
| 447 | 447 |
| 448 #endif | 448 #endif |
| LEFT | RIGHT |