michael@0: /* This Source Code Form is subject to the terms of the Mozilla Public michael@0: * License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ michael@0: michael@0: #include "mozilla/ModuleUtils.h" michael@0: #include "nsIServiceManager.h" michael@0: #include "nsContentBlocker.h" michael@0: #include "nsXPIDLString.h" michael@0: michael@0: // Define the constructor function for the objects michael@0: NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsContentBlocker, Init) michael@0: michael@0: NS_DEFINE_NAMED_CID(NS_CONTENTBLOCKER_CID); michael@0: michael@0: static const mozilla::Module::CIDEntry kPermissionsCIDs[] = { michael@0: { &kNS_CONTENTBLOCKER_CID, false, nullptr, nsContentBlockerConstructor }, michael@0: { nullptr } michael@0: }; michael@0: michael@0: static const mozilla::Module::ContractIDEntry kPermissionsContracts[] = { michael@0: { NS_CONTENTBLOCKER_CONTRACTID, &kNS_CONTENTBLOCKER_CID }, michael@0: { nullptr } michael@0: }; michael@0: michael@0: static const mozilla::Module::CategoryEntry kPermissionsCategories[] = { michael@0: { "content-policy", NS_CONTENTBLOCKER_CONTRACTID, NS_CONTENTBLOCKER_CONTRACTID }, michael@0: { nullptr } michael@0: }; michael@0: michael@0: static const mozilla::Module kPermissionsModule = { michael@0: mozilla::Module::kVersion, michael@0: kPermissionsCIDs, michael@0: kPermissionsContracts, michael@0: kPermissionsCategories michael@0: }; michael@0: michael@0: NSMODULE_DEFN(nsPermissionsModule) = &kPermissionsModule;