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

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

Issue 5739415347396608: Expose extractHostFromURL to API (Closed)
Patch Set: Created April 22, 2014, 7: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 | lib/api.js » ('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 <http://adblockplus.org/>, 2 * This file is part of Adblock Plus <http://adblockplus.org/>,
3 * Copyright (C) 2006-2014 Eyeo GmbH 3 * Copyright (C) 2006-2014 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 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 std::vector<SubscriptionPtr> FetchAvailableSubscriptions() const; 81 std::vector<SubscriptionPtr> FetchAvailableSubscriptions() const;
82 FilterPtr Matches(const std::string& url, 82 FilterPtr Matches(const std::string& url,
83 const std::string& contentType, 83 const std::string& contentType,
84 const std::string& documentUrl) const; 84 const std::string& documentUrl) const;
85 FilterPtr Matches(const std::string& url, 85 FilterPtr Matches(const std::string& url,
86 const std::string& contentType, 86 const std::string& contentType,
87 const std::vector<std::string>& documentUrls) const; 87 const std::vector<std::string>& documentUrls) const;
88 std::vector<std::string> GetElementHidingSelectors(const std::string& domain ) const; 88 std::vector<std::string> GetElementHidingSelectors(const std::string& domain ) const;
89 JsValuePtr GetPref(const std::string& pref) const; 89 JsValuePtr GetPref(const std::string& pref) const;
90 void SetPref(const std::string& pref, JsValuePtr value); 90 void SetPref(const std::string& pref, JsValuePtr value);
91 std::string GetHostFromURL(const std::string& url);
91 void ForceUpdateCheck(UpdaterCallback callback = 0); 92 void ForceUpdateCheck(UpdaterCallback callback = 0);
92 void SetFilterChangeCallback(FilterChangeCallback callback); 93 void SetFilterChangeCallback(FilterChangeCallback callback);
93 void RemoveFilterChangeCallback(); 94 void RemoveFilterChangeCallback();
94 95
95 private: 96 private:
96 JsEnginePtr jsEngine; 97 JsEnginePtr jsEngine;
97 bool initialized; 98 bool initialized;
98 bool firstRun; 99 bool firstRun;
99 int updateCheckId; 100 int updateCheckId;
100 101
101 void InitDone(JsValueList& params); 102 void InitDone(JsValueList& params);
102 FilterPtr CheckFilterMatch(const std::string& url, 103 FilterPtr CheckFilterMatch(const std::string& url,
103 const std::string& contentType, 104 const std::string& contentType,
104 const std::string& documentUrl) const; 105 const std::string& documentUrl) const;
105 void UpdateCheckDone(const std::string& eventName, UpdaterCallback callback, JsValueList& params); 106 void UpdateCheckDone(const std::string& eventName, UpdaterCallback callback, JsValueList& params);
106 void FilterChanged(FilterChangeCallback callback, JsValueList& params); 107 void FilterChanged(FilterChangeCallback callback, JsValueList& params);
107 }; 108 };
108 } 109 }
109 110
110 #endif 111 #endif
OLDNEW
« no previous file with comments | « no previous file | lib/api.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld