public void WaitForAvailable(int timeout)
 {
     HPAccessControlWindow.WaitForAvailable(timeout);
     QuotaCheckBox.WaitForAvailable(timeout);
     DelegateCheckBox.WaitForAvailable(timeout);
     IPMCheckBox.WaitForAvailable(timeout);
     LocaljobstorageCheckBox.WaitForAvailable(timeout);
 }
        public override PluginExecutionResult PerformAction()
        {
            WaitForAvailable(ShortTimeout);
            if (_setQuota)
            {
                if (QuotaCheckBox.Check(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Select Quota Configuration"));
                }
            }
            else
            {
                if (QuotaCheckBox.Uncheck(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Unselect Quota Configuration"));
                }
            }
            if (_setDelegate)
            {
                if (DelegateCheckBox.Check(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Select Delegate Configuration"));
                }
            }
            else
            {
                if (DelegateCheckBox.Uncheck(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Unselect Delegate Configuration"));
                }
            }
            if (_setIPM)
            {
                if (IPMCheckBox.Check(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Select IPM Configuration"));
                }
            }
            else
            {
                if (IPMCheckBox.Uncheck(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Unselect Delegate Configuration"));
                }
            }
            if (_setLocalJobStorage)
            {
                if (LocaljobstorageCheckBox.Check(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Select LocalJobStorage Configuration"));
                }
            }
            else
            {
                if (LocaljobstorageCheckBox.Uncheck(ShortTimeout) != ResultCode.Passed)
                {
                    return(new PluginExecutionResult(PluginResult.Failed, "Failed to Unselect LocalJobStorage Configuration"));
                }
            }

            Thread.Sleep(HumanTimeSpan);

            if (NextButton.Click(ShortTimeout) != ResultCode.Passed)
            {
                return(new PluginExecutionResult(PluginResult.Failed, string.Format("Failed to proceed beyond {0} Screen", ScreenName)));
            }
            return(new PluginExecutionResult(PluginResult.Passed));
        }