public List<String> getAllHostSystems() throws VMWareException {

        ServiceInstance si = null;

        List<String> hostSystems = new ArrayList<String>();

        try {

            si = this.getServerInstance();
            ManagedEntity[] hostsystems = new InventoryNavigator(si.getRootFolder()).searchManagedEntities("HostSystem");
            for (ManagedEntity hostsystem : hostsystems) {
                HostSystem host = (HostSystem) hostsystem;

                hostSystems.add(host.getName());
            }

            return hostSystems;

        } catch (PlatformConfigFault f) {
            throw new VMWareException(f);
        } catch (RemoteException exc) {
            throw new VMWareException(exc);
        } catch (Exception exc) {
            throw new VMWareException(exc);
        }
    }