@Sample(name="get-hostname",
description="This sample gets the hostname and additional details of the ESX Servers in the inventory")
public class GetHostName
extends VCenterSampleBase
GetHostName This sample gets the hostname and additional details of the ESX Servers in the inventory Parameters: url [required] : url of the web service username [required] : username for the authentication password [required] : password for the authentication Command Line: run.bat com.vmware.general.GetHostName --url [webservicesurl] --username [username] --password [password]
ConnectedVimServiceBase.ConnectionExceptionPROP_ME_NAME, SVC_INST_NAME| Constructor and Description |
|---|
GetHostName() |
| Modifier and Type | Method and Description |
|---|---|
void |
printHostProductDetails()
Prints the Host names.
|
void |
setHostSystemAttributesList() |
connectbasicConnectionFromConnection, disconnect, getServiceInstanceReference, setConnection, setHostConnectionpublic void setHostSystemAttributesList()
@Action
public void printHostProductDetails()
throws com.vmware.vim25.InvalidPropertyFaultMsg,
com.vmware.vim25.RuntimeFaultFaultMsg
com.vmware.vim25.RuntimeFaultFaultMsgcom.vmware.vim25.InvalidPropertyFaultMsg