Package javaforce.vm

Class VirtualMachine

java.lang.Object
javaforce.vm.VirtualMachine
All Implemented Interfaces:
Serializable

public class VirtualMachine extends Object implements Serializable
See Also:
  • Field Details

  • Constructor Details

    • VirtualMachine

      public VirtualMachine(Hardware hardware)
  • Method Details

    • init

      public static boolean init()
    • getPool

      public String getPool()
    • getName

      public String getName()
    • getVNC

      public int getVNC()
    • getUUID

      public String getUUID()
    • getPath

      public String getPath()
    • getFolder

      public String getFolder()
    • getFile

      public String getFile()
    • loadHardware

      public Hardware loadHardware()
    • saveHardware

      public boolean saveHardware(Hardware hardware)
    • create_stats_folder

      public void create_stats_folder()
    • check_write_access

      public boolean check_write_access()
    • start

      public boolean start()
    • stop

      public boolean stop()
    • poweroff

      public boolean poweroff()
    • restart

      public boolean restart()
    • suspend

      public boolean suspend()
    • resume

      public boolean resume()
    • getState

      public int getState()
    • getStateString

      public String getStateString()
    • getState

      public static int getState(String state)
    • getStates

      public String[] getStates()
    • list

      public static VirtualMachine[] list()
    • get

      public static VirtualMachine get(String name)
    • register

      public static boolean register(VirtualMachine vm, Hardware hardware, VMProvider provider)
    • reregister

      public boolean reregister(Hardware hardware, VMProvider provider)
    • unregister

      public boolean unregister()
    • migrateCompute

      public boolean migrateCompute(String desthost, boolean live, Status status)
      Live/offline VM migration.
    • migrateData

      public boolean migrateData(Storage dest_pool, Hardware hw, Status status, VMProvider provider)
      Offline only VM storage migration.
    • cloneData

      public boolean cloneData(Storage dest_pool, String new_name, Status status, VMProvider provider)
      Offline only VM storage clone.
    • backupData

      public boolean backupData(String host, String pool, String folder, String host_token, Status status)
    • snapshotCreate

      public boolean snapshotCreate(String name, String desc, int flags)
      Snap Shot : Create
    • snapshotList

      public Snapshot[] snapshotList()
      Snap Shot : List
    • snapshotCount

      public int snapshotCount()
      Return number of snapshots.
    • snapshotGetByName

      public Snapshot snapshotGetByName(String snapshot)
      Returns snapshot by name.
    • snapshotExists

      public boolean snapshotExists()
      Determines if VM is running on a snapshot.
    • snapshotGetCurrent

      public Snapshot snapshotGetCurrent()
      Returns current snapshot VM is running on.
    • snapshotRestore

      public boolean snapshotRestore(String name)
      Snap Shot : Restore
    • snapshotDelete

      public boolean snapshotDelete(String name)
      Snap Shot : Delete (merges data back into parent)
    • hasSnapshot

      public boolean hasSnapshot()
    • main

      public static void main(String[] args)