|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.ntnu.item.jt.VMware.VMwareServer
public class VMwareServer
Representents a VMware server.
Field Summary | |
---|---|
static boolean |
debug
|
static int |
VIX_API_VERSION
|
static int |
VIX_INVALID_HANDLE
|
static long |
VIX_OK
|
static int |
VIX_PROPERTY_JOB_RESULT_HANDLE
|
static int |
VIX_PROPERTY_NONE
|
static int |
VIX_SERVICEPROVIDER_DEFAULT
|
static int |
VIX_SERVICEPROVIDER_VMWARE_SERVER
|
static int |
VIX_SERVICEPROVIDER_VMWARE_WORKSTATION
|
static int |
VIX_VMPOWEROP_NORMAL
|
(package private) VixInterface |
vixLib
|
Constructor Summary | |
---|---|
VMwareServer(String hostname,
int portNumber)
Create a new VMwareServer instance. |
Method Summary | |
---|---|
void |
connect(String serverUsername,
String serverPassword)
Connect to a VMWare Server. |
void |
disconnect()
Disconnect from the guest OS and free the resources. |
protected String |
getHost()
Getter for the hostname of this VMware server. |
protected int |
getHostHandle()
Getter for the host handle of the VMware server (only has meaning for vix (and log files)). |
static void |
main(String[] args)
Contains code used for testing VMwareServer and GuestOS. |
GuestOS |
openVM(String vmxFilePathName,
String username,
String password)
Load a VM in the VMWare server. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int VIX_API_VERSION
public static final int VIX_SERVICEPROVIDER_DEFAULT
public static final int VIX_SERVICEPROVIDER_VMWARE_SERVER
public static final int VIX_SERVICEPROVIDER_VMWARE_WORKSTATION
public static final int VIX_INVALID_HANDLE
public static final int VIX_PROPERTY_NONE
public static final int VIX_PROPERTY_JOB_RESULT_HANDLE
public static final int VIX_VMPOWEROP_NORMAL
public static final long VIX_OK
public static boolean debug
VixInterface vixLib
Constructor Detail |
---|
public VMwareServer(String hostname, int portNumber)
hostname
- host running VMware server.Method Detail |
---|
public void connect(String serverUsername, String serverPassword) throws ConnectionFailedException
serverUsername
- user name of the user running VMWare.serverPassword
- password of the user running VMWare.
ConnectionFailedException
- thrown to indicate a connection failure.public GuestOS openVM(String vmxFilePathName, String username, String password) throws OpenVMException
vmxFilePathName
- Full path name to the .vmx VMWare config file on the VMWare server host.username
- user name for the virtual machine.password
- password for the virtual machine. If none is required, supply null.
OpenVMException
- thrown if opening the VM failed.GuestOS
public void disconnect()
protected int getHostHandle()
protected String getHost()
public static void main(String[] args) throws Exception
args
-
Exception
- not handled.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |