Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: include/AdblockPlus/FilterEngine.h

Issue 29508569: Issue 5450 - don't expose std::shared_ptr<JsEngine> (Closed) Base URL: https://github.com/adblockplus/libadblockplus.git
Patch Set: Created Aug. 7, 2017, 8:39 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | include/AdblockPlus/Platform.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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-2017 eyeo GmbH 3 * Copyright (C) 2006-2017 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
293 * @param parameters optional creation parameters. 293 * @param parameters optional creation parameters.
294 */ 294 */
295 static void CreateAsync(const JsEnginePtr& jsEngine, 295 static void CreateAsync(const JsEnginePtr& jsEngine,
296 const OnCreatedCallback& onCreated, 296 const OnCreatedCallback& onCreated,
297 const CreationParameters& parameters = CreationParameters()); 297 const CreationParameters& parameters = CreationParameters());
298 298
299 /** 299 /**
300 * Retrieves the `JsEngine` instance associated with this `FilterEngine` 300 * Retrieves the `JsEngine` instance associated with this `FilterEngine`
301 * instance. 301 * instance.
302 */ 302 */
303 JsEnginePtr GetJsEngine() const { return jsEngine; } 303 JsEngine& GetJsEngine() const { return *jsEngine; }
304 304
305 /** 305 /**
306 * Checks if this is the first run of the application. 306 * Checks if this is the first run of the application.
307 * @return `true` if the application is running for the first time. 307 * @return `true` if the application is running for the first time.
308 */ 308 */
309 bool IsFirstRun() const; 309 bool IsFirstRun() const;
310 310
311 /** 311 /**
312 * Retrieves a filter object from its text representation. 312 * Retrieves a filter object from its text representation.
313 * @param text Text representation of the filter, 313 * @param text Text representation of the filter,
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 void FilterChanged(const FilterChangeCallback& callback, JsValueList&& param s) const; 566 void FilterChanged(const FilterChangeCallback& callback, JsValueList&& param s) const;
567 FilterPtr GetWhitelistingFilter(const std::string& url, 567 FilterPtr GetWhitelistingFilter(const std::string& url,
568 ContentTypeMask contentTypeMask, const std::string& documentUrl) const; 568 ContentTypeMask contentTypeMask, const std::string& documentUrl) const;
569 FilterPtr GetWhitelistingFilter(const std::string& url, 569 FilterPtr GetWhitelistingFilter(const std::string& url,
570 ContentTypeMask contentTypeMask, 570 ContentTypeMask contentTypeMask,
571 const std::vector<std::string>& documentUrls) const; 571 const std::vector<std::string>& documentUrls) const;
572 }; 572 };
573 } 573 }
574 574
575 #endif 575 #endif
OLDNEW
« no previous file with comments | « no previous file | include/AdblockPlus/Platform.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld