Exemple #1
0
 public void QuickClose()
 {
     if (ReportStack.Any())
     {
         ReportStack.Peek().QuickClose();
     }
 }
Exemple #2
0
        public void PopReport()
        {
            if (!ReportStack.Any())
            {
                throw new InvalidOperationException("Stack is empty");
            }
            ReportStack.Pop();

            // There should always be the "default report" waiting on the stack.
            if (!ReportStack.Any())
            {
                throw new InvalidOperationException("Stack is empty");
            }
            Scope.DefaultScope = Report;
        }
Exemple #3
0
        public void PopReport()
        {
            if (!ReportStack.Any())
            {
                throw new InvalidOperationException("Stack is empty");
            }

            ReportStack.Peek().QuickClose(); // DM - this code simulates calling Report's destructor at this moment
            ReportStack.Pop();

            // There should always be the "default report" waiting on the stack.
            if (!ReportStack.Any())
            {
                throw new InvalidOperationException("Stack is empty");
            }
            Scope.DefaultScope = Report;
        }