PopDebuggerStack() private method

private PopDebuggerStack ( ) : void
return void
示例#1
0
 internal override void Execute(Processor processor, ActionFrame frame)
 {
     if (frame.State == Initialized)
     {
         processor.PushDebuggerStack();
         processor.OnInstructionExecute();
         processor.PushDebuggerStack();
     }
     base.Execute(processor, frame);
     if (frame.State == Finished)
     {
         processor.PopDebuggerStack();
         processor.PopDebuggerStack();
     }
 }
示例#2
0
        internal override void Execute(Processor processor, ActionFrame frame)
        {
            Debug.Assert(processor != null && frame != null);

            switch (frame.State)
            {
            case Initialized:
                frame.AllocateVariables(variableCount);
                XPathNavigator root = processor.Document.Clone();
                root.MoveToRoot();
                frame.InitNodeSet(new XPathSingletonIterator(root));

                if (this.containedActions != null && this.containedActions.Count > 0)
                {
                    processor.PushActionFrame(frame);
                }
                frame.State = QueryInitialized;
                break;

            case QueryInitialized:
                Debug.Assert(frame.State == QueryInitialized);
                frame.NextNode(processor);
                Debug.Assert(Processor.IsRoot(frame.Node));
                if (processor.Debugger != null)
                {
                    // this is like apply-templates, but we don't have it on stack.
                    // Pop the stack, otherwise last instruction will be on it.
                    processor.PopDebuggerStack();
                }
                processor.PushTemplateLookup(frame.NodeSet, /*mode:*/ null, /*importsOf:*/ null);

                frame.State = RootProcessed;
                break;

            case RootProcessed:
                Debug.Assert(frame.State == RootProcessed);
                frame.Finished();
                break;

            default:
                Debug.Fail("Invalid RootAction execution state");
                break;
            }
        }
 internal override void Execute(Processor processor, ActionFrame frame) {
     if(frame.State == Initialized) {
         processor.PushDebuggerStack();
         processor.OnInstructionExecute();
     }
     base.Execute(processor, frame);
     if (frame.State == Finished) {
         processor.PopDebuggerStack();
     }
 }
       internal override void Execute(Processor processor, ActionFrame frame) {
            Debug.Assert(processor != null && frame != null);

            switch (frame.State) {
            case Initialized:
                frame.AllocateVariables(variableCount);
                XPathNavigator root = processor.Document.Clone();
                root.MoveToRoot();
                frame.InitNodeSet(new XPathSingletonIterator(root));
               
                if (this.containedActions != null && this.containedActions.Count > 0) {
                    processor.PushActionFrame(frame);
                }
                frame.State = QueryInitialized;
                break;
            case QueryInitialized:
                Debug.Assert(frame.State == QueryInitialized);
                frame.NextNode(processor);
                Debug.Assert(Processor.IsRoot(frame.Node));
                if (processor.Debugger != null) {
                    // this is like apply-templates, but we don't have it on stack. 
                    // Pop the stack, otherwise last instruction will be on it.
                    processor.PopDebuggerStack();
                }
                processor.PushTemplateLookup(frame.NodeSet, /*mode:*/null, /*importsOf:*/null);

                frame.State = RootProcessed;
                break;

            case RootProcessed:
                Debug.Assert(frame.State == RootProcessed);
                frame.Finished();
                break;
            default:
                Debug.Fail("Invalid RootAction execution state");
		        break;
            }
        }