struct CCL::IServiceManager

Overview

#include <iservicemanager.h>

struct IServiceManager: public CCL::IUnknown
{
    // methods

    virtual void CCL_API startup (IProgressNotify* progress = nullptr) = 0;
    virtual void CCL_API shutdown () = 0;
    virtual tbool CCL_API canShutdown () const = 0;
    virtual int CCL_API countServices () const = 0;
    virtual const IServiceDescription*CCL_API getService (int index) const = 0;
    virtual tresult CCL_API getInstance (UIDRef cid, UIDRef iid, void** object) const = 0;

    template  <class Interface>
    Interface* getInstance (UIDRef cid = kNullUID);

    virtual tresult CCL_API enableService (
        const IServiceDescription& description,
        tbool state
    ) = 0;

    virtual void CCL_API registerNotification (IServiceNotification* notification) = 0;
    virtual void CCL_API unregisterNotification (IServiceNotification* notification) = 0;
};

Inherited Members

public:
    // methods

    virtual tresult CCL_API queryInterface (UIDRef iid, void** ptr) = 0;
    virtual unsigned int CCL_API retain () = 0;
    virtual unsigned int CCL_API release () = 0;

Detailed Documentation

Methods

virtual void CCL_API startup (IProgressNotify* progress = nullptr) = 0

Start services.

virtual void CCL_API shutdown () = 0

Shutdown services.

virtual tbool CCL_API canShutdown () const = 0

Check if services can shutdown now.

virtual int CCL_API countServices () const = 0

Get number of installed services.

virtual const IServiceDescription*CCL_API getService (int index) const = 0

Get service description by index.

virtual tresult CCL_API getInstance (UIDRef cid, UIDRef iid, void** object) const = 0

Get service instance by interface/class identifier.

template  <class Interface>
Interface* getInstance (UIDRef cid = kNullUID)

Get service instance by interface/class identifier.

virtual tresult CCL_API enableService (
    const IServiceDescription& description,
    tbool state
) = 0

Enable/disable service.

virtual void CCL_API registerNotification (IServiceNotification* notification) = 0

Register service notification.

virtual void CCL_API unregisterNotification (IServiceNotification* notification) = 0

Unregister service notification.