Visit Mozilla.org

NS GetServiceManager

From MDC

« XPCOM API Reference

Contents

[edit] Summary

The NS_GetServiceManager function returns a reference to the XPCOM service manager.

#include "nsXPCOM.h"
#include "nsIServiceManager.h"
 
nsresult NS_GetServiceManager(
  nsIServiceManager** aResult
);

[edit] Parameters

aResult
[out] A reference to the XPCOM service manager.

[edit] Return Values

The NS_GetServiceManager function returns NS_OK if successful. Otherwise, it returns an error code.

[edit] Remarks

The object returned is a singleton that is valid until NS_ShutdownXPCOM is called. The interface pointer should be Release'd when it is no longer needed.

[edit] History

This function was finalized for Mozilla 0.9.6. See bug 99147 for details.

[edit] See Also

nsIServiceManager