Ejemplo n.º 1
0
 public void ReconnectHost(HostConnectSpec cnxSpec, HostSystemReconnectSpec reconnectSpec)
 {
     try
     {
         ManagedObjectReference taskReference = this.ReconnectHost_Task(cnxSpec, reconnectSpec);
         this.Client.WaitForTask(taskReference);
     }
     catch (FaultException ex)
     {
         throw FaultUtility.HandleFault(ex);
     }
 }
Ejemplo n.º 2
0
        public ManagedObjectReference AddStandaloneHost(HostConnectSpec spec, ComputeResourceConfigSpec compResSpec, bool addConnected, string license)
        {
            ManagedObjectReference result;

            try
            {
                ManagedObjectReference taskReference = this.AddStandaloneHost_Task(spec, compResSpec, addConnected, license);
                result = (ManagedObjectReference)this.Client.WaitForTask(taskReference);
            }
            catch (FaultException ex)
            {
                throw FaultUtility.HandleFault(ex);
            }
            return(result);
        }
Ejemplo n.º 3
0
        public ManagedObjectReference AddHost(HostConnectSpec spec, bool asConnected, ManagedObjectReference resourcePool, string license)
        {
            ManagedObjectReference result;

            try
            {
                ManagedObjectReference taskReference = this.AddHost_Task(spec, asConnected, resourcePool, license);
                result = (ManagedObjectReference)this.Client.WaitForTask(taskReference);
            }
            catch (FaultException ex)
            {
                throw FaultUtility.HandleFault(ex);
            }
            return(result);
        }
 public ClusterEVCManagerCheckResult[] CheckAddHostEvc(HostConnectSpec cnxSpec)
 {
     ClusterEVCManagerCheckResult[] result;
     try
     {
         VersionUtils.RequiresVersion(this.Client, VimVersion.Vim60);
         ManagedObjectReference taskReference = this.CheckAddHostEvc_Task(cnxSpec);
         result = (ClusterEVCManagerCheckResult[])this.Client.WaitForTask(taskReference);
     }
     catch (FaultException ex)
     {
         throw FaultUtility.HandleFault(ex);
     }
     return(result);
 }
Ejemplo n.º 5
0
        public ManagedObjectReference ReconnectHost_Task(HostConnectSpec cnxSpec, HostSystemReconnectSpec reconnectSpec)
        {
            ManagedObjectReference result;

            try
            {
                ReconnectHostRequestType reconnectHostRequestType = new ReconnectHostRequestType();
                reconnectHostRequestType._this         = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(this.MoRef);
                reconnectHostRequestType.cnxSpec       = (VimApi_65.HostConnectSpec)VIConvert.ToWsdlType(cnxSpec);
                reconnectHostRequestType.reconnectSpec = (VimApi_65.HostSystemReconnectSpec)VIConvert.ToWsdlType(reconnectSpec);
                result = (ManagedObjectReference)VIConvert.ToVim(this.VimServiceProxy.ReconnectHost_Task(new ReconnectHost_TaskRequest(reconnectHostRequestType)).ReconnectHost_TaskResponse.returnval);
            }
            catch (FaultException ex)
            {
                throw FaultUtility.HandleFault(ex);
            }
            return(result);
        }
Ejemplo n.º 6
0
        public HostConnectInfo QueryConnectionInfoViaSpec(HostConnectSpec spec)
        {
            HostConnectInfo result;

            try
            {
                VersionUtils.RequiresVersion(this.Client, VimVersion.Vim60);
                QueryConnectionInfoViaSpecRequestType queryConnectionInfoViaSpecRequestType = new QueryConnectionInfoViaSpecRequestType();
                queryConnectionInfoViaSpecRequestType._this = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(this.MoRef);
                queryConnectionInfoViaSpecRequestType.spec  = (VimApi_65.HostConnectSpec)VIConvert.ToWsdlType(spec);
                result = (HostConnectInfo)VIConvert.ToVim(this.VimServiceProxy.QueryConnectionInfoViaSpec(new QueryConnectionInfoViaSpecRequest(queryConnectionInfoViaSpecRequestType)).QueryConnectionInfoViaSpecResponse.returnval);
            }
            catch (FaultException ex)
            {
                throw FaultUtility.HandleFault(ex);
            }
            return(result);
        }
        public ManagedObjectReference CheckAddHostEvc_Task(HostConnectSpec cnxSpec)
        {
            ManagedObjectReference result;

            try
            {
                VersionUtils.RequiresVersion(this.Client, VimVersion.Vim60);
                CheckAddHostEvcRequestType checkAddHostEvcRequestType = new CheckAddHostEvcRequestType();
                checkAddHostEvcRequestType._this   = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(this.MoRef);
                checkAddHostEvcRequestType.cnxSpec = (VimApi_65.HostConnectSpec)VIConvert.ToWsdlType(cnxSpec);
                result = (ManagedObjectReference)VIConvert.ToVim(this.VimServiceProxy.CheckAddHostEvc_Task(new CheckAddHostEvc_TaskRequest(checkAddHostEvcRequestType)).CheckAddHostEvc_TaskResponse.returnval);
            }
            catch (FaultException ex)
            {
                throw FaultUtility.HandleFault(ex);
            }
            return(result);
        }
Ejemplo n.º 8
0
        public ManagedObjectReference AddStandaloneHost_Task(HostConnectSpec spec, ComputeResourceConfigSpec compResSpec, bool addConnected, string license)
        {
            ManagedObjectReference result;

            try
            {
                AddStandaloneHostRequestType addStandaloneHostRequestType = new AddStandaloneHostRequestType();
                addStandaloneHostRequestType._this        = (VimApi_65.ManagedObjectReference)VIConvert.ToWsdlType(this.MoRef);
                addStandaloneHostRequestType.spec         = (VimApi_65.HostConnectSpec)VIConvert.ToWsdlType(spec);
                addStandaloneHostRequestType.compResSpec  = (VimApi_65.ComputeResourceConfigSpec)VIConvert.ToWsdlType(compResSpec);
                addStandaloneHostRequestType.addConnected = addConnected;
                addStandaloneHostRequestType.license      = license;
                result = (ManagedObjectReference)VIConvert.ToVim(this.VimServiceProxy.AddStandaloneHost_Task(new AddStandaloneHost_TaskRequest(addStandaloneHostRequestType)).AddStandaloneHost_TaskResponse.returnval);
            }
            catch (FaultException ex)
            {
                throw FaultUtility.HandleFault(ex);
            }
            return(result);
        }