Inheritance: Microsoft.Azure.Commands.Batch.Models.JobOperationParameters
        /// <summary>
        /// Disables the specified job.
        /// </summary>
        /// <param name="parameters">Specifies the job to disable as well as the job disable option.</param>
        public void DisableJob(DisableJobParameters parameters)
        {
            if (parameters == null)
            {
                throw new ArgumentNullException("parameters");
            }

            string jobId = parameters.Job == null ? parameters.JobId : parameters.Job.Id;

            WriteVerbose(string.Format(Resources.DisableJob, jobId));

            JobOperations jobOperations = parameters.Context.BatchOMClient.JobOperations;

            jobOperations.DisableJob(jobId, parameters.DisableJobOption, parameters.AdditionalBehaviors);
        }
 public override void ExecuteCmdlet()
 {
     DisableJobParameters parameters = new DisableJobParameters(this.BatchContext, this.Id, null, this.DisableJobOption, this.AdditionalBehaviors);
     BatchClient.DisableJob(parameters);
 }
        /// <summary>
        /// Disables the specified job.
        /// </summary>
        /// <param name="parameters">Specifies the job to disable as well as the job disable option.</param>
        public void DisableJob(DisableJobParameters parameters)
        {
            if (parameters == null)
            {
                throw new ArgumentNullException("parameters");
            }

            string jobId = parameters.Job == null ? parameters.JobId : parameters.Job.Id;

            WriteVerbose(string.Format(Resources.DisableJob, jobId));

            JobOperations jobOperations = parameters.Context.BatchOMClient.JobOperations;
            jobOperations.DisableJob(jobId, parameters.DisableJobOption, parameters.AdditionalBehaviors);
        }
 protected override void ProcessRecord()
 {
     DisableJobParameters parameters = new DisableJobParameters(this.BatchContext, this.Id, null, this.DisableJobOption, this.AdditionalBehaviors);
     BatchClient.DisableJob(parameters);
 }