public void UpdateIpPool(ManagedObjectReference dc, IpPool pool) { try { VersionUtils.RequiresVersion(this.Client, VimVersion.Vim4); UpdateIpPoolRequestType updateIpPoolRequestType = new UpdateIpPoolRequestType(); updateIpPoolRequestType._this = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(this.MoRef); updateIpPoolRequestType.dc = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(dc); updateIpPoolRequestType.pool = (VimApi_65.IpPool)VIConvert.ToWsdlType(pool); this.VimServiceProxy.UpdateIpPool(new UpdateIpPoolRequest(updateIpPoolRequestType)); } catch (FaultException ex) { throw FaultUtility.HandleFault(ex); } }
public int CreateIpPool(ManagedObjectReference dc, IpPool pool) { int returnval; try { VersionUtils.RequiresVersion(this.Client, VimVersion.Vim4); CreateIpPoolRequestType createIpPoolRequestType = new CreateIpPoolRequestType(); createIpPoolRequestType._this = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(this.MoRef); createIpPoolRequestType.dc = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(dc); createIpPoolRequestType.pool = (VimApi_65.IpPool)VIConvert.ToWsdlType(pool); returnval = this.VimServiceProxy.CreateIpPool(new CreateIpPoolRequest(createIpPoolRequestType)).CreateIpPoolResponse.returnval; } catch (FaultException ex) { throw FaultUtility.HandleFault(ex); } return(returnval); }