@Sample(name="get-updates",
description="This sample demonstrates how to use the PropertyCollector to monitor one or more properties of one or more managed objects.")
public class GetUpdates
extends ConnectedVimServiceBase
GetUpdates This sample demonstrates how to use the PropertyCollector to monitor one or more properties of one or more managed objects. In particular this sample monitors all or one Virtual Machine for changes to some basic properties Parameters: url [required] : url of the web service username [required] : username for the authentication password [required] : password for the authentication vmname [optional] : name of the virtual machine (if not defined sample will get the updates for all the VM under VMfolder) Command Line: run.bat com.vmware.general.GetUpdates --url [webserviceurl] --username [username] --password [password] --vmname [vm name]
ConnectedVimServiceBase.ConnectionExceptionPROP_ME_NAME, SVC_INST_NAME| Constructor and Description |
|---|
GetUpdates() |
| Modifier and Type | Method and Description |
|---|---|
void |
action() |
void |
getUpdates() |
void |
setVmname(java.lang.String name) |
basicConnectionFromConnection, connect, disconnect, getServiceInstanceReference, setConnection, setHostConnection@Option(name="vmname",
description="name of the virtual machine",
required=false)
public void setVmname(java.lang.String name)
public void getUpdates()
throws com.vmware.vim25.RuntimeFaultFaultMsg,
java.io.IOException,
com.vmware.vim25.InvalidCollectorVersionFaultMsg,
com.vmware.vim25.InvalidPropertyFaultMsg
com.vmware.vim25.RuntimeFaultFaultMsgjava.io.IOExceptioncom.vmware.vim25.InvalidCollectorVersionFaultMsgcom.vmware.vim25.InvalidPropertyFaultMsg@Action
public void action()
throws com.vmware.vim25.RuntimeFaultFaultMsg,
java.io.IOException,
com.vmware.vim25.InvalidPropertyFaultMsg,
com.vmware.vim25.InvalidCollectorVersionFaultMsg
com.vmware.vim25.RuntimeFaultFaultMsgjava.io.IOExceptioncom.vmware.vim25.InvalidPropertyFaultMsgcom.vmware.vim25.InvalidCollectorVersionFaultMsg