Package com.vmware.vim25.mo

Examples of com.vmware.vim25.mo.Folder


    
    TaskManager taskMgr = si.getTaskManager();

    if(taskMgr!=null)
    {
      Folder root = si.getRootFolder();
      TaskFilterSpec tfs = createTaskFilterSpec(root);
      TaskHistoryCollector thc =
          taskMgr.createCollectorForTasks(tfs);
     
      // Note: 10 <= pagesize <= 62
View Full Code Here


public class CacheFrameworkSample
{
  public static void main(String[] args) throws Exception
  {
    ServiceInstance si = new ServiceInstance(new URL("http://10.20.143.205/sdk"), "root", "password", true);
    Folder rootFolder = si.getRootFolder();
    ManagedEntity[] vms = new InventoryNavigator(rootFolder).searchManagedEntities("VirtualMachine");
    ManagedEntity[] hosts = new InventoryNavigator(rootFolder).searchManagedEntities("HostSystem");
 
    CacheInstance vicf = new CacheInstance(si);
    vicf.watch(vms, new String[] {"name", "runtime.powerState", "summary"});
View Full Code Here

     
    System.out.println("Host Name : " + host.getName());
    System.out.println("Network : " + host.getNetworks()[0].getName());
    System.out.println("Datastore : " + host.getDatastores()[0].getName());

    Folder vmFolder = (Folder) host.getVms()[0].getParent();

    OvfCreateImportSpecParams importSpecParams = new OvfCreateImportSpecParams();
    importSpecParams.setHostSystem(host.getMOR());
    importSpecParams.setLocale("US");
    importSpecParams.setEntityName(newVmName);
View Full Code Here

    String hostname = "dev.acme.com";
    String portGroupName = "ViMaster PortGroup";
    String switchName = "ViMaster Switch";

    Folder rootFolder = si.getRootFolder();
    HostSystem host = null;
    host = (HostSystem) new InventoryNavigator(
        rootFolder).searchManagedEntity("HostSystem", hostname);

    HostNetworkSystem hns = host.getHostNetworkSystem();
View Full Code Here

    return;
    }
   
    ServiceInstance si = new ServiceInstance(
                new URL(args[0]), args[1], args[2], true);
    Folder rootFolder = si.getRootFolder();
   
    InventoryNavigator inv = new InventoryNavigator(rootFolder);
    String vmname = args[3];
    VirtualMachine vm = (VirtualMachine)inv.searchManagedEntity(
            "VirtualMachine", vmname);
View Full Code Here

    ServiceInstance si = new ServiceInstance(
        new URL(args[0]), args[1], args[2], true);

    String hostname = args[3];
    Folder rootFolder = si.getRootFolder();
    HostSystem host = null;
    host = (HostSystem) new InventoryNavigator(
        rootFolder).searchManagedEntity("HostSystem", hostname);

    if(host==null)
View Full Code Here

    ServiceInstance si = new ServiceInstance(
      new URL(args[0]), args[1], args[2], true);
   
    String hostname = "sjin-dev1.eng.vmware.com";

    Folder rootFolder = si.getRootFolder();
    HostSystem host = null;

    host = (HostSystem) new InventoryNavigator(
        rootFolder).searchManagedEntity("HostSystem", hostname);
 
View Full Code Here

      System.exit(0);
    }

    ServiceInstance si = new ServiceInstance(
        new URL(args[0]), args[1], args[2], true);
    Folder root = si.getRootFolder();
    ManagedEntity[] mes = new InventoryNavigator(
        root).searchManagedEntities("ClusterComputeResource");
    if(mes==null || mes.length == 0)
    {
      System.out.println("There is no DRS cluster. Exiting.");
View Full Code Here

    String cloneName = args[4];

    ServiceInstance si = new ServiceInstance(
        new URL(args[0]), args[1], args[2], true);

    Folder rootFolder = si.getRootFolder();
    VirtualMachine vm = (VirtualMachine) new InventoryNavigator(
        rootFolder).searchManagedEntity(
            "VirtualMachine", vmname);

    if(vm==null)
View Full Code Here

    String diskName = args[4];
    ServiceInstance si = new ServiceInstance(
        new URL(args[0]), args[1], args[2], true);

    Folder rootFolder = si.getRootFolder();
    VirtualMachine vm = (VirtualMachine) new InventoryNavigator(
      rootFolder).searchManagedEntity("VirtualMachine", vmname);

    if(vm==null)
    {
View Full Code Here

TOP

Related Classes of com.vmware.vim25.mo.Folder

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.