3.2.1.2 Service and Providers
IVdsService::GetObject: "XXX" is a placeholder for provider, pack, disk, virtual disk, volume, volume plex, or HBA port. Prior to invoking GetObject, the client invokes QueryXXXs on interfaces that have a QueryXXXs method. The server responds with an IEnumVdsObject interface, which enumerates a list of IUnknown interfaces, one for each object that is associated with the enumeration. The client invokes IUnknown::QueryInterface to retrieve an IVdsXXX interface on the object. The client invokes IVdsXXX::GetProperties to retrieve the object ID. The client passes this returned value as the id input parameter to the GetObject method. IVdsXXX::GetProperties returns this value as the VDS_PROVIDER_PROP id member, VDS_PACK_PROP id member, VDS_DISK_PROP id member, VDS_VDISK_PROPERTIES Id member, VDS_VOLUME_PROP id member, VDS_VOLUME_PLEX_PROP id member, or VDS_HBAPORT_PROP id member. The client can cache the object IDs for the lifetime of the object; it can later be used to retrieve an interface to the object without having to cache the interface to the object itself, or having to enumerate and find the object every time it needs the object.
IVdsService::Advise: Prior to invoking Advise, the client calls IVdsService::WaitForServiceReady or polls by using IVdsService::IsServiceReady successfully. The client invokes IVdsService::Advise to retrieve the client identification value parameter. The client passes the client identification value as the dwCookie input parameter to the Unadvise method.
IVdsService::Unadvise: Prior to invoking Unadvise, the client invokes IVdsService::Advise to retrieve the client identification value. The client passes the client identification value as the dwCookie input parameter to the Unadvise method.