Fri, 16 Jan 2015 18:13:44 +0100
Integrate suggestion from review to improve consistency with existing code.
1 # This Source Code Form is subject to the terms of the Mozilla Public
2 # License, v. 2.0. If a copy of the MPL was not distributed with this
3 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
5 // We wastefully reload the same JS files across components. This puts all
6 // the common JS files used by safebrowsing and url-classifier into a
7 // single component.
9 const Cc = Components.classes;
10 const Ci = Components.interfaces;
11 const G_GDEBUG = false;
13 Components.utils.import("resource://gre/modules/XPCOMUtils.jsm");
15 #include ./content/moz/lang.js
16 #include ./content/moz/preferences.js
17 #include ./content/moz/debug.js
18 #include ./content/moz/alarm.js
19 #include ./content/moz/cryptohasher.js
20 #include ./content/moz/observer.js
21 #include ./content/moz/protocol4.js
23 #include ./content/request-backoff.js
24 #include ./content/xml-fetcher.js
26 // Expose this whole component.
27 var lib = this;
29 function UrlClassifierLib() {
30 this.wrappedJSObject = lib;
31 }
32 UrlClassifierLib.prototype.classID = Components.ID("{26a4a019-2827-4a89-a85c-5931a678823a}");
33 UrlClassifierLib.prototype.QueryInterface = XPCOMUtils.generateQI([]);
35 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([UrlClassifierLib]);