Exemple #1
0
        /// <summary>
        /// BeginProcessing method.
        /// </summary>
        protected override void BeginProcessing()
        {
            CimRemoveCimInstance cimRemoveInstance = this.GetOperationAgent() ?? CreateOperationAgent();

            this.CmdletOperation = new CmdletOperationRemoveCimInstance(this, cimRemoveInstance);
            this.AtBeginProcess  = false;
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="CmdletOperationRemoveCimInstance"/> class.
 /// </summary>
 /// <param name="cmdlet"></param>
 public CmdletOperationRemoveCimInstance(Cmdlet cmdlet,
                                         CimRemoveCimInstance cimRemoveCimInstance)
     : base(cmdlet)
 {
     ValidationHelper.ValidateNoNullArgument(cimRemoveCimInstance, cimRemoveCimInstanceParameterName);
     this.removeCimInstance = cimRemoveCimInstance;
 }
Exemple #3
0
        /// <summary>
        /// ProcessRecord method.
        /// </summary>
        protected override void ProcessRecord()
        {
            base.CheckParameterSet();
            CimRemoveCimInstance cimRemoveInstance = this.GetOperationAgent();

            cimRemoveInstance.RemoveCimInstance(this);
            cimRemoveInstance.ProcessActions(this.CmdletOperation);
        }
Exemple #4
0
        /// <summary>
        /// EndProcessing method.
        /// </summary>
        protected override void EndProcessing()
        {
            CimRemoveCimInstance cimRemoveInstance = this.GetOperationAgent();

            if (cimRemoveInstance != null)
            {
                cimRemoveInstance.ProcessRemainActions(this.CmdletOperation);
            }
        }