13.07.2015 Views

[MS-VDS]: Virtual Disk Service (VDS) Protocol Specification

[MS-VDS]: Virtual Disk Service (VDS) Protocol Specification

[MS-VDS]: Virtual Disk Service (VDS) Protocol Specification

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

•If the task completed successfully, set the percentage completed value in the async object to100.•Set the signal state in the async object to TRUE.At any point in the preceding sequence--before the percentage completed value in the async objectis 100--the server MUST update the percentage completed value if progress has been made.3.4.5.2.16.3 IVdsVdProvider::AddV<strong>Disk</strong> (Opnum 5)The AddV<strong>Disk</strong> method creates a virtual disk object representing the specified virtual disk and addsit to the list of virtual disks managed by the provider. This method returns an IVdsV<strong>Disk</strong> (section3.1.15.1) interface pointer to the specified virtual disk object.HRESULT AddV<strong>Disk</strong>([in] PVIRTUAL_STORAGE_TYPE <strong>Virtual</strong>DeviceType,[in, string] LPWSTR pPath,[in, out, unique] IVdsV<strong>Disk</strong>** ppV<strong>Disk</strong>);<strong>Virtual</strong>DeviceType: A pointer to a VIRTUAL_STORAGE_TYPE (section 2.2.1.3.23) structurethat specifies the type of virtual hard disk to open.pPath: A NULL-terminated wide-character string containing the fully qualified pathname for thevirtual disk's backing file.ppV<strong>Disk</strong>: A pointer to a variable that, if the operation is successfully completed, receives anIVdsV<strong>Disk</strong> interface pointer to the newly created virtual disk object. Callers MUST release theinterface pointer when it is no longer needed by calling the IUnknown::Release method.Return Values: The method MUST return zero or a nonerror HRESULT (as specified in [<strong>MS</strong>-ERREF]) to indicate success, or return an implementation-specific nonzero error code toindicate failure. For the HRESULT values predefined by the <strong>Virtual</strong> <strong>Disk</strong> <strong>Service</strong> Remote<strong>Protocol</strong>, see section 2.2.3.When the server receives this message, it MUST validate the following parameters:•Verify that <strong>Virtual</strong>DeviceType is not NULL.•Verify that pPath is not NULL.•Verify that ppV<strong>Disk</strong> is not NULL.The server MUST then perform the following in sequence:•Search its cached virtual disk objects for an object whose file name matches the input pPath. Ifsuch an object does not exist, create a new virtual disk cache object that implements theIVdsV<strong>Disk</strong> interface and assign it a unique <strong>VDS</strong>_OBJECT_ID (section 2.2.1.1.3).•Point ppV<strong>Disk</strong> to an IVdsV<strong>Disk</strong> interface of the virtual disk object found or created and return anHRESULT indicating success.3.4.5.2.16.4 IVdsVdProvider::Get<strong>Disk</strong>FromV<strong>Disk</strong> (Opnum 6)The Get<strong>Disk</strong>FromV<strong>Disk</strong> method returns an IVds<strong>Disk</strong> (section 3.1.12.1) interface pointer for avirtual disk given an IVdsV<strong>Disk</strong> (section 3.1.15.1) interface pointer.[<strong>MS</strong>-<strong>VDS</strong>] — v20110610<strong>Virtual</strong> <strong>Disk</strong> <strong>Service</strong> (<strong>VDS</strong>) <strong>Protocol</strong> <strong>Specification</strong>Copyright © 2011 Microsoft Corporation.Release: Friday, June 10, 2011193 / 360

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!