cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From h...@apache.org
Subject [6/7] git commit: updated refs/heads/vmwaresdk-to-vijava to 02ae858
Date Sun, 22 Sep 2013 12:10:57 GMT
Convert a whole bunch of files from Vmware SDK to vijava


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/ddd58c88
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/ddd58c88
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/ddd58c88

Branch: refs/heads/vmwaresdk-to-vijava
Commit: ddd58c8898576dfab3aaa0dd8f387e76589e526e
Parents: 1846bba
Author: Hugo Trippaers <htrippaers@schubergphilis.com>
Authored: Sun Sep 22 19:41:59 2013 +0800
Committer: Hugo Trippaers <htrippaers@schubergphilis.com>
Committed: Sun Sep 22 19:41:59 2013 +0800

----------------------------------------------------------------------
 .../vmware/mo/DistributedVirtualSwitchMO.java   | 13 +++++------
 .../vmware/mo/HostDatastoreBrowserMO.java       | 14 ++++++------
 .../vmware/mo/HostDatastoreSystemMO.java        | 24 ++++++++++----------
 .../vmware/mo/HostStorageSystemMO.java          |  4 ++--
 .../hypervisor/vmware/mo/HttpNfcLeaseMO.java    | 10 ++++----
 .../vmware/mo/HypervisorHostHelper.java         |  1 -
 .../vmware/mo/LicenseAssignmentManagerMO.java   |  8 +++----
 .../vmware/mo/VirtualDiskManagerMO.java         | 20 ++++++++--------
 8 files changed, 46 insertions(+), 48 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/DistributedVirtualSwitchMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/DistributedVirtualSwitchMO.java
b/vmware-base/src/com/cloud/hypervisor/vmware/mo/DistributedVirtualSwitchMO.java
index b00b97c..fde4bea 100644
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/DistributedVirtualSwitchMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/DistributedVirtualSwitchMO.java
@@ -46,20 +46,20 @@ public class DistributedVirtualSwitchMO extends BaseMO {
     public void createDVPortGroup(DVPortgroupConfigSpec dvPortGroupSpec) throws Exception
{
         List<DVPortgroupConfigSpec> dvPortGroupSpecArray = new ArrayList<DVPortgroupConfigSpec>();
         dvPortGroupSpecArray.add(dvPortGroupSpec);
-        _context.getService().addDVPortgroupTask(_mor, dvPortGroupSpecArray);
+        _context.getService().addDVPortgroup_Task(_mor, dvPortGroupSpecArray.toArray(new
DVPortgroupConfigSpec[0]));
     }
 
     public void updateDvPortGroup(ManagedObjectReference dvPortGroupMor, DVPortgroupConfigSpec
dvPortGroupSpec) throws Exception {
         // TODO(sateesh): Update numPorts
-        _context.getService().reconfigureDVPortgroupTask(dvPortGroupMor, dvPortGroupSpec);
+        _context.getService().reconfigureDVPortgroup_Task(dvPortGroupMor, dvPortGroupSpec);
     }
 
     public void updateVMWareDVSwitch(ManagedObjectReference dvSwitchMor, VMwareDVSConfigSpec
dvsSpec) throws Exception {
-        _context.getService().reconfigureDvsTask(dvSwitchMor, dvsSpec);
+        _context.getService().reconfigureDvs_Task(dvSwitchMor, dvsSpec);
     }
 
     public TaskInfo updateVMWareDVSwitchGetTask(ManagedObjectReference dvSwitchMor, VMwareDVSConfigSpec
dvsSpec) throws Exception {
-        ManagedObjectReference task = _context.getService().reconfigureDvsTask(dvSwitchMor,
dvsSpec);
+        ManagedObjectReference task = _context.getService().reconfigureDvs_Task(dvSwitchMor,
dvsSpec);
         TaskInfo info = (TaskInfo) (_context.getVimClient().getDynamicProperty(task, "info"));
         boolean waitvalue = _context.getVimClient().waitForTask(task);
         return info;
@@ -77,10 +77,9 @@ public class DistributedVirtualSwitchMO extends BaseMO {
         Map<Integer, HypervisorHostHelper.PvlanType> result = new HashMap<Integer,
HypervisorHostHelper.PvlanType>();
 
         VMwareDVSConfigInfo configinfo = (VMwareDVSConfigInfo)_context.getVimClient().getDynamicProperty(dvSwitchMor,
"config");
-        List<VMwareDVSPvlanMapEntry> pvlanconfig = null;
-        pvlanconfig = configinfo.getPvlanConfig();
+        VMwareDVSPvlanMapEntry[] pvlanconfig = configinfo.getPvlanConfig();
 
-        if (null == pvlanconfig || 0 == pvlanconfig.size()) {
+        if (null == pvlanconfig || 0 == pvlanconfig.length) {
             return result;
         }
         // Iterate through the pvlanMapList and check if the specified vlan id and pvlan
id exist. If they do, set the fields in result accordingly.

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreBrowserMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreBrowserMO.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreBrowserMO.java
index 209aeed..8ef4b40 100644
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreBrowserMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreBrowserMO.java
@@ -39,7 +39,7 @@ public class HostDatastoreBrowserMO extends BaseMO {
 
 	public void DeleteFile(String datastoreFullPath) throws Exception {
 		if(s_logger.isTraceEnabled())
-			s_logger.trace("vCenter API trace - deleteFile(). target mor: " + _mor.getValue() + ",
file datastore path: " + datastoreFullPath);
+			s_logger.trace("vCenter API trace - deleteFile(). target mor: " + _mor.getVal() + ", file
datastore path: " + datastoreFullPath);
 
 		_context.getService().deleteFile(_mor, datastoreFullPath);
 
@@ -49,10 +49,10 @@ public class HostDatastoreBrowserMO extends BaseMO {
 
 	public HostDatastoreBrowserSearchResults searchDatastore(String datastorePath, HostDatastoreBrowserSearchSpec
searchSpec) throws Exception {
 		if(s_logger.isTraceEnabled())
-			s_logger.trace("vCenter API trace - searchDatastore(). target mor: " + _mor.getValue()
+ ", file datastore path: " + datastorePath);
+			s_logger.trace("vCenter API trace - searchDatastore(). target mor: " + _mor.getVal() +
", file datastore path: " + datastorePath);
 
 		try {
-			ManagedObjectReference morTask = _context.getService().searchDatastoreTask(_mor, datastorePath,
searchSpec);
+			ManagedObjectReference morTask = _context.getService().searchDatastore_Task(_mor, datastorePath,
searchSpec);
 
 			boolean result = _context.getVimClient().waitForTask(morTask);
 			if(result) {
@@ -73,7 +73,7 @@ public class HostDatastoreBrowserMO extends BaseMO {
 	public HostDatastoreBrowserSearchResults searchDatastore(String datastorePath, String fileName,
boolean caseInsensitive) throws Exception {
 		HostDatastoreBrowserSearchSpec spec = new HostDatastoreBrowserSearchSpec();
 		spec.setSearchCaseInsensitive(caseInsensitive);
-		spec.getMatchPattern().add(fileName);
+		spec.setMatchPattern(new String[] {fileName});
 
 		return searchDatastore(datastorePath, spec);
 	}
@@ -81,10 +81,10 @@ public class HostDatastoreBrowserMO extends BaseMO {
     @SuppressWarnings("unchecked")
     public ArrayList<HostDatastoreBrowserSearchResults> searchDatastoreSubFolders(String
datastorePath, HostDatastoreBrowserSearchSpec searchSpec) throws Exception {
 		if(s_logger.isTraceEnabled())
-			s_logger.trace("vCenter API trace - searchDatastoreSubFolders(). target mor: " + _mor.getValue()
+ ", file datastore path: " + datastorePath);
+			s_logger.trace("vCenter API trace - searchDatastoreSubFolders(). target mor: " + _mor.getVal()
+ ", file datastore path: " + datastorePath);
 
 		try {
-			ManagedObjectReference morTask = _context.getService().searchDatastoreSubFoldersTask(_mor,
datastorePath, searchSpec);
+			ManagedObjectReference morTask = _context.getService().searchDatastoreSubFolders_Task(_mor,
datastorePath, searchSpec);
 
 			boolean result = _context.getVimClient().waitForTask(morTask);
 			if(result) {
@@ -105,7 +105,7 @@ public class HostDatastoreBrowserMO extends BaseMO {
     public ArrayList<HostDatastoreBrowserSearchResults> searchDatastoreSubFolders(String
datastorePath, String fileName, boolean caseInsensitive) throws Exception {
         HostDatastoreBrowserSearchSpec spec = new HostDatastoreBrowserSearchSpec();
         spec.setSearchCaseInsensitive(caseInsensitive);
-        spec.getMatchPattern().add(fileName);
+        spec.setMatchPattern(new String[] {fileName});
 
         return searchDatastoreSubFolders(datastorePath, spec);
     }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreSystemMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreSystemMO.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreSystemMO.java
index 45c1c07..ca482b3 100755
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreSystemMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostDatastoreSystemMO.java
@@ -54,15 +54,15 @@ public class HostDatastoreSystemMO extends BaseMO {
 		int key = cfmMo.getCustomFieldKey("Datastore", CustomFieldConstants.CLOUD_UUID);
 		assert(key != 0);
 
-		List<ObjectContent> ocs = getDatastorePropertiesOnHostDatastoreSystem(
+		ObjectContent[] ocs = getDatastorePropertiesOnHostDatastoreSystem(
 			new String[] { "name", String.format("value[%d]", key) });
 		if(ocs != null) {
 			for(ObjectContent oc : ocs) {
-				if(oc.getPropSet().get(0).getVal().equals(name))
+				if(oc.getPropSet()[0].getVal().equals(name))
 					return oc.getObj();
 
-				if(oc.getPropSet().size() > 1) {
-					DynamicProperty prop = oc.getPropSet().get(1);
+				if(oc.getPropSet().length > 1) {
+					DynamicProperty prop = oc.getPropSet()[1];
 					if(prop != null && prop.getVal() != null) {
 						if(prop.getVal() instanceof CustomFieldStringValue) {
 							String val = ((CustomFieldStringValue)prop.getVal()).getValue();
@@ -143,13 +143,13 @@ public class HostDatastoreSystemMO extends BaseMO {
 		return null;
 	}
 
-	public List<HostScsiDisk> queryAvailableDisksForVmfs() throws Exception {
+	public HostScsiDisk[] queryAvailableDisksForVmfs() throws Exception {
 		return _context.getService().queryAvailableDisksForVmfs(_mor, null);
 	}
 
 	public ManagedObjectReference createVmfsDatastore(String datastoreName, HostScsiDisk hostScsiDisk)
throws Exception {
 		// just grab the first instance of VmfsDatastoreOption
-		VmfsDatastoreOption vmfsDatastoreOption = _context.getService().queryVmfsDatastoreCreateOptions(_mor,
hostScsiDisk.getDevicePath(), 5).get(0);
+		VmfsDatastoreOption vmfsDatastoreOption = _context.getService().queryVmfsDatastoreCreateOptions(_mor,
hostScsiDisk.getDevicePath(), 5)[0];
 
 		VmfsDatastoreCreateSpec vmfsDatastoreCreateSpec = (VmfsDatastoreCreateSpec)vmfsDatastoreOption.getSpec();
 
@@ -198,11 +198,11 @@ public class HostDatastoreSystemMO extends BaseMO {
 		return null;
 	}
 
-	public List<ObjectContent> getDatastorePropertiesOnHostDatastoreSystem(String[] propertyPaths)
throws Exception {
+	public ObjectContent[] getDatastorePropertiesOnHostDatastoreSystem(String[] propertyPaths)
throws Exception {
 
 		PropertySpec pSpec = new PropertySpec();
 		pSpec.setType("Datastore");
-		pSpec.getPathSet().addAll(Arrays.asList(propertyPaths));
+		pSpec.setPathSet(propertyPaths);
 
 	    TraversalSpec hostDsSys2DatastoreTraversal = new TraversalSpec();
 	    hostDsSys2DatastoreTraversal.setType("HostDatastoreSystem");
@@ -212,15 +212,15 @@ public class HostDatastoreSystemMO extends BaseMO {
 	    ObjectSpec oSpec = new ObjectSpec();
 	    oSpec.setObj(_mor);
 	    oSpec.setSkip(Boolean.TRUE);
-	    oSpec.getSelectSet().add(hostDsSys2DatastoreTraversal);
+	    oSpec.setSelectSet(new TraversalSpec[] { hostDsSys2DatastoreTraversal});
 
 	    PropertyFilterSpec pfSpec = new PropertyFilterSpec();
-	    pfSpec.getPropSet().add(pSpec);
-	    pfSpec.getObjectSet().add(oSpec);
+	    pfSpec.setPropSet(new PropertySpec[] { pSpec });
+	    pfSpec.setObjectSet(new ObjectSpec[] { oSpec });
         List<PropertyFilterSpec> pfSpecArr = new ArrayList<PropertyFilterSpec>();
         pfSpecArr.add(pfSpec);
 
 	    return _context.getService().retrieveProperties(
-	    	_context.getPropertyCollector(), pfSpecArr);
+	    	_context.getPropertyCollector(), pfSpecArr.toArray(new PropertyFilterSpec[0]));
 	}
 }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostStorageSystemMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostStorageSystemMO.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostStorageSystemMO.java
index a7d8e66..0270091 100644
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostStorageSystemMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HostStorageSystemMO.java
@@ -38,11 +38,11 @@ public class HostStorageSystemMO extends BaseMO {
 	}
 	
 	public void addInternetScsiStaticTargets(String iScsiHbaDevice, List<HostInternetScsiHbaStaticTarget>
lstTargets) throws Exception {
-		_context.getService().addInternetScsiStaticTargets(_mor, iScsiHbaDevice, lstTargets);
+		_context.getService().addInternetScsiStaticTargets(_mor, iScsiHbaDevice, lstTargets.toArray(new
HostInternetScsiHbaStaticTarget[0]));
 	}
 	
 	public void removeInternetScsiStaticTargets(String iScsiHbaDevice, List<HostInternetScsiHbaStaticTarget>
lstTargets) throws Exception {
-		_context.getService().removeInternetScsiStaticTargets(_mor, iScsiHbaDevice, lstTargets);
+		_context.getService().removeInternetScsiStaticTargets(_mor, iScsiHbaDevice, lstTargets.toArray(new
HostInternetScsiHbaStaticTarget[0]));
 	}
 	
 	public void rescanHba(String iScsiHbaDevice) throws Exception {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/HttpNfcLeaseMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HttpNfcLeaseMO.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HttpNfcLeaseMO.java
index ca36280..4349d41 100755
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HttpNfcLeaseMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HttpNfcLeaseMO.java
@@ -60,9 +60,9 @@ public class HttpNfcLeaseMO extends BaseMO {
             stateVal = stateElement.getFirstChild().getTextContent();
         }
         if (stateVal != null) {
-            return HttpNfcLeaseState.fromValue(stateVal);
+            return HttpNfcLeaseState.valueOf(stateVal);
         }
-        return HttpNfcLeaseState.ERROR;
+        return HttpNfcLeaseState.error;
 	}
 
 	public HttpNfcLeaseState waitState(HttpNfcLeaseState[] states) throws Exception {
@@ -72,7 +72,7 @@ public class HttpNfcLeaseMO extends BaseMO {
 		HttpNfcLeaseState state;
 		while(true) {
 			state = getState();
-			if(state == HttpNfcLeaseState.READY || state == HttpNfcLeaseState.ERROR)
+			if(state == HttpNfcLeaseState.ready || state == HttpNfcLeaseState.error)
 				return state;
 		}
 	}
@@ -83,7 +83,7 @@ public class HttpNfcLeaseMO extends BaseMO {
 		return (HttpNfcLeaseInfo)_context.getVimClient().getDynamicProperty(_mor, "info");
 	}
 
-	public List<HttpNfcLeaseManifestEntry> getLeaseManifest() throws Exception {
+	public HttpNfcLeaseManifestEntry[] getLeaseManifest() throws Exception {
 		return _context.getService().httpNfcLeaseGetManifest(_mor);
 	}
 
@@ -110,7 +110,7 @@ public class HttpNfcLeaseMO extends BaseMO {
 	}
 
 	public static long calcTotalBytes(OvfCreateImportSpecResult ovfImportResult) {
-		List<OvfFileItem> fileItemArr = ovfImportResult.getFileItem();
+		OvfFileItem[] fileItemArr = ovfImportResult.getFileItem();
 		long totalBytes = 0;
 		if (fileItemArr != null) {
 			for (OvfFileItem fi : fileItemArr) {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
index 3a70744..88ba4f1 100755
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
@@ -27,7 +27,6 @@ import java.util.Map;
 
 import org.apache.log4j.Logger;
 
-import com.vmware.vim25.AlreadyExistsFaultMsg;
 import com.vmware.vim25.BoolPolicy;
 import com.vmware.vim25.CustomFieldStringValue;
 import com.vmware.vim25.DVPortSetting;

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/LicenseAssignmentManagerMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/LicenseAssignmentManagerMO.java
b/vmware-base/src/com/cloud/hypervisor/vmware/mo/LicenseAssignmentManagerMO.java
index 0a86b97..bb8af0f 100644
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/LicenseAssignmentManagerMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/LicenseAssignmentManagerMO.java
@@ -45,15 +45,15 @@ public class LicenseAssignmentManagerMO extends BaseMO {
     }
 
     public LicenseAssignmentManagerLicenseAssignment getAssignedLicenseToHost(ManagedObjectReference
hostMor) throws Exception {
-        List<LicenseAssignmentManagerLicenseAssignment> licenses = _context.getVimClient().getService().queryAssignedLicenses(_mor,
hostMor.getValue());
-        return licenses.get(0);
+        LicenseAssignmentManagerLicenseAssignment[] licenses = _context.getVimClient().getService().queryAssignedLicenses(_mor,
hostMor.getVal());
+        return licenses[0];
     }
 
     public boolean isFeatureSupported(String featureKey, ManagedObjectReference hostMor)
throws Exception {
         boolean featureSupported = false;
 
         // Retrieve host license properties
-        List<KeyAnyValue> props = getHostLicenseProperties(hostMor);
+        KeyAnyValue[] props = getHostLicenseProperties(hostMor);
 
         // Check host license properties to see if specified feature is supported by the
license.
         for (KeyAnyValue prop : props) {
@@ -76,7 +76,7 @@ public class LicenseAssignmentManagerMO extends BaseMO {
         return license.getAssignedLicense();
     }
 
-    public List<KeyAnyValue> getHostLicenseProperties(ManagedObjectReference hostMor)
throws Exception {
+    public KeyAnyValue[] getHostLicenseProperties(ManagedObjectReference hostMor) throws
Exception {
         return getHostLicenseInfo(hostMor).getProperties();
     }
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ddd58c88/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualDiskManagerMO.java
----------------------------------------------------------------------
diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualDiskManagerMO.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualDiskManagerMO.java
index f181d02..bc608e8 100755
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualDiskManagerMO.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualDiskManagerMO.java
@@ -42,7 +42,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     	String destName, ManagedObjectReference morDestDc, VirtualDiskSpec diskSpec,
     	boolean force) throws Exception {
 
-    	ManagedObjectReference morTask = _context.getService().copyVirtualDiskTask(_mor, srcName,
morSrcDc, destName, morDestDc, diskSpec, force);
+    	ManagedObjectReference morTask = _context.getService().copyVirtualDisk_Task(_mor, srcName,
morSrcDc, destName, morDestDc, diskSpec, force);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -53,7 +53,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void createVirtualDisk(String name, ManagedObjectReference morDc, VirtualDiskSpec
diskSpec) throws Exception {
-    	ManagedObjectReference morTask = _context.getService().createVirtualDiskTask(_mor, name,
morDc, diskSpec);
+    	ManagedObjectReference morTask = _context.getService().createVirtualDisk_Task(_mor,
name, morDc, diskSpec);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -64,7 +64,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void defragmentVirtualDisk(String name, ManagedObjectReference morDc) throws Exception
{
-    	ManagedObjectReference morTask = _context.getService().defragmentVirtualDiskTask(_mor,
name, morDc);
+    	ManagedObjectReference morTask = _context.getService().defragmentVirtualDisk_Task(_mor,
name, morDc);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -74,7 +74,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void deleteVirtualDisk(String name, ManagedObjectReference morDc) throws Exception
{
-    	ManagedObjectReference morTask = _context.getService().deleteVirtualDiskTask(_mor, name,
morDc);
+    	ManagedObjectReference morTask = _context.getService().deleteVirtualDisk_Task(_mor,
name, morDc);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -84,7 +84,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void eagerZeroVirtualDisk(String name, ManagedObjectReference morDc) throws Exception
{
-    	ManagedObjectReference morTask = _context.getService().eagerZeroVirtualDiskTask(_mor,
name, morDc);
+    	ManagedObjectReference morTask = _context.getService().eagerZeroVirtualDisk_Task(_mor,
name, morDc);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -94,7 +94,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void extendVirtualDisk(String name, ManagedObjectReference morDc, long newCapacityKb,
boolean eagerZero) throws Exception {
-    	ManagedObjectReference morTask = _context.getService().extendVirtualDiskTask(_mor, name,
morDc, newCapacityKb, eagerZero);
+    	ManagedObjectReference morTask = _context.getService().extendVirtualDisk_Task(_mor,
name, morDc, newCapacityKb, eagerZero);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -104,7 +104,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void inflateVirtualDisk(String name, ManagedObjectReference morDc) throws Exception
{
-    	ManagedObjectReference morTask = _context.getService().inflateVirtualDiskTask(_mor,
name, morDc);
+    	ManagedObjectReference morTask = _context.getService().inflateVirtualDisk_Task(_mor,
name, morDc);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -113,7 +113,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void shrinkVirtualDisk(String name, ManagedObjectReference morDc, boolean copy)
throws Exception {
-    	ManagedObjectReference morTask = _context.getService().shrinkVirtualDiskTask(_mor, name,
morDc, copy);
+    	ManagedObjectReference morTask = _context.getService().shrinkVirtualDisk_Task(_mor,
name, morDc, copy);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -122,7 +122,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     }
 
     public void zeroFillVirtualDisk(String name, ManagedObjectReference morDc) throws Exception
{
-    	ManagedObjectReference morTask = _context.getService().zeroFillVirtualDiskTask(_mor,
name, morDc);
+    	ManagedObjectReference morTask = _context.getService().zeroFillVirtualDisk_Task(_mor,
name, morDc);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);
 		if(!result)
@@ -133,7 +133,7 @@ public class VirtualDiskManagerMO extends BaseMO {
     public void moveVirtualDisk(String srcName, ManagedObjectReference morSrcDc,
     	String destName, ManagedObjectReference morDestDc, boolean force) throws Exception {
 
-    	ManagedObjectReference morTask = _context.getService().moveVirtualDiskTask(_mor, srcName,
morSrcDc,
+    	ManagedObjectReference morTask = _context.getService().moveVirtualDisk_Task(_mor, srcName,
morSrcDc,
     		destName, morDestDc, force);
 
 		boolean result = _context.getVimClient().waitForTask(morTask);


Mime
View raw message