Package com.vmware.vim.binding.vim

Examples of com.vmware.vim.binding.vim.Datastore


            if (vDisk == null)
               return null;

            VirtualDisk.FlatVer2BackingInfo backing =
                  (VirtualDisk.FlatVer2BackingInfo) vDisk.getBacking();
            Datastore ds = MoUtil.getManagedObject(backing.getDatastore());
            diskEntity.setSizeInMB((int) (vDisk.getCapacityInKB() / 1024));
            diskEntity.setDatastoreName(ds.getName());
            diskEntity.setVmdkPath(backing.getFileName());
            diskEntity.setDatastoreMoId(MoUtil.morefToString(ds._getRef()));
            diskEntity.setDiskMode(backing.getDiskMode());
            diskEntity.setHardwareUUID(backing.getUuid());
            return null;
         }
      });
View Full Code Here


   private boolean inStoragePod;
   private Datastore.HostMount[] hosts;

   @Override
   protected void update(ManagedObject mo) {
      Datastore ds = (Datastore) mo;
      summary = ds.getSummary();
      info = ds.getInfo();
      datacenter = MoUtil.getAncestorMoRef(ds.getParent(), Datacenter.class);
      inStoragePod = MoUtil.isOfType(ds.getParent(), StoragePod.class);
      hosts = ds.getHost();
   }
View Full Code Here

      final SearchSpec spec = new DatastoreBrowser_Impl.SearchSpecImpl();
      spec.setMatchPattern(new String[]{fname});
      VcTask task = VcContext.getTaskMgr().execute(new IVcTaskBody() {
         @Override
         public VcTask body() throws Exception {
            Datastore mo = ds.getManagedObject();
            DatastoreBrowser browser = MoUtil.getManagedObject(mo.getBrowser());
            return new VcTask(TaskType.SearchFile,
                              browser.search(dsPath, spec), callback);
         }
      });
      return task;
View Full Code Here

TOP

Related Classes of com.vmware.vim.binding.vim.Datastore

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.