michael@0: /* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ 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: /** michael@0: * The nsIComponentManager interface. michael@0: */ michael@0: michael@0: #include "nsISupports.idl" michael@0: michael@0: interface nsIFile; michael@0: interface nsIFactory; michael@0: interface nsIArray; michael@0: michael@0: [scriptable, uuid(d604ffc3-1ba3-4f6c-b65f-1ed4199364c3)] michael@0: interface nsIComponentManager : nsISupports michael@0: { michael@0: /** michael@0: * getClassObject michael@0: * michael@0: * Returns the factory object that can be used to create instances of michael@0: * CID aClass michael@0: * michael@0: * @param aClass The classid of the factory that is being requested michael@0: */ michael@0: void getClassObject(in nsCIDRef aClass, michael@0: in nsIIDRef aIID, michael@0: [iid_is(aIID),retval] out nsQIResult result); michael@0: michael@0: /** michael@0: * getClassObjectByContractID michael@0: * michael@0: * Returns the factory object that can be used to create instances of michael@0: * CID aClass michael@0: * michael@0: * @param aClass The classid of the factory that is being requested michael@0: */ michael@0: void getClassObjectByContractID(in string aContractID, michael@0: in nsIIDRef aIID, michael@0: [iid_is(aIID),retval] out nsQIResult result); michael@0: michael@0: michael@0: /** michael@0: * createInstance michael@0: * michael@0: * Create an instance of the CID aClass and return the interface aIID. michael@0: * michael@0: * @param aClass : ClassID of object instance requested michael@0: * @param aDelegate : Used for aggregation michael@0: * @param aIID : IID of interface requested michael@0: */ michael@0: void createInstance(in nsCIDRef aClass, michael@0: in nsISupports aDelegate, michael@0: in nsIIDRef aIID, michael@0: [iid_is(aIID),retval] out nsQIResult result); michael@0: michael@0: /** michael@0: * createInstanceByContractID michael@0: * michael@0: * Create an instance of the CID that implements aContractID and return the michael@0: * interface aIID. michael@0: * michael@0: * @param aContractID : aContractID of object instance requested michael@0: * @param aDelegate : Used for aggregation michael@0: * @param aIID : IID of interface requested michael@0: */ michael@0: void createInstanceByContractID(in string aContractID, michael@0: in nsISupports aDelegate, michael@0: in nsIIDRef aIID, michael@0: [iid_is(aIID),retval] out nsQIResult result); michael@0: michael@0: /** michael@0: * addBootstrappedManifestLocation michael@0: * michael@0: * Adds a bootstrapped manifest location on runtime. michael@0: * michael@0: * @param aLocation : A directory where chrome.manifest resides, michael@0: * or an XPI with it on the root. michael@0: */ michael@0: void addBootstrappedManifestLocation(in nsIFile aLocation); michael@0: michael@0: /** michael@0: * removeBootstrappedManifestLocation michael@0: * michael@0: * Removes a bootstrapped manifest location on runtime. michael@0: * michael@0: * @param aLocation : A directory where chrome.manifest resides, michael@0: * or an XPI with it on the root. michael@0: */ michael@0: void removeBootstrappedManifestLocation(in nsIFile aLocation); michael@0: michael@0: /** michael@0: * getManifestLocations michael@0: * michael@0: * Get an array of nsIURIs of all registered and builtin manifest locations. michael@0: */ michael@0: nsIArray getManifestLocations(); michael@0: }; michael@0: michael@0: michael@0: %{ C++ michael@0: #ifdef MOZILLA_INTERNAL_API michael@0: #include "nsComponentManagerUtils.h" michael@0: #endif michael@0: %} C++