Collapse All
Parallels Desktop® 10 for Mac — C API Reference Guide
PrlVm_RefreshConfig Function
PHT_VIRTUAL_MACHINE

The PrlVm_RefreshConfig function updates the configuration information contained in the specified virtual machine object (handle).

Syntax
PRL_HANDLE PrlVm_RefreshConfig(
    PRL_HANDLE hVm
);
File

PrlApiVm.h

Parameters

hVm
A handle of type PHT_VIRTUAL_MACHINE identifying the virtual machine. This is the object that will be updated.
Returns

A handle of type PHT_JOB containing the results of this asynchronous operation or PRL_INVALID_HANDLE if there's not enough memory to instantiate the job object.

Remarks

When you obtain a virtual machine handle that refers to an existing virtual machine, it is populated with the virtual machine configuration data. When working with configuration data, you always work with this local copy. Naturally, the configuration can change on the Parallels Service side at any time. The PrlVm_RefreshConfig function allows to re-retrieve the configuration data from the Parallels Service. The function can be used when an event of type PET_DSP_EVT_VM_CONFIG_CHANGED is triggered (the event notifies the client that the virtual machine configuration has been modified), or on unsuccessful PrlVm_Commit operation, or at any time you want to synchronize your local virtual machine object with the Parallels Service. Please note that the function replaces the local data, so if you made any modification to it, the changes will be lost.

To get the return code from the PHT_JOB object, use the PrlJob_GetRetCode function. Possible values are:

PRL_ERR_INVALID_ARG - invalid handle or null pointer was passed.

PRL_ERR_SUCCESS - function completed successfully.

Links
Copyright © 1999-2015 Parallels IP Holdings GmbH and its affiliates. All rights reserved.
What do you think about this topic? Send feedback!