Esempio n. 1
0
        public PrtFunStack Clone()
        {
            var clonedStack = new PrtFunStack();

            foreach (var frame in funStack)
            {
                clonedStack.funStack.Push(frame.Clone());
            }
            clonedStack.funStack.Reverse();
            return(clonedStack);
        }
Esempio n. 2
0
        public PrtMachine()
        {
            this.instanceNumber   = 0;
            this.fields           = new List <PrtValue>();
            this.eventValue       = PrtValue.NullValue;
            this.stateStack       = new PrtStateStack();
            this.invertedFunStack = new PrtFunStack();
            this.continuation     = new PrtContinuation();
            this.currentTrigger   = PrtValue.NullValue;
            this.currentPayload   = PrtValue.NullValue;
            this.currentStatus    = PrtMachineStatus.Enabled;
            this.nextSMOperation  = PrtNextStatemachineOperation.EntryOperation;
            this.stateExitReason  = PrtStateExitReason.NotExit;

            this.stateImpl = null;
        }
Esempio n. 3
0
 public PrtMachine()
 {
     this.instanceNumber   = 0;
     this.fields           = new List <PrtValue>();
     this.eventValue       = PrtValue.@null;
     this.stateStack       = new PrtStateStack();
     this.invertedFunStack = new PrtFunStack();
     this.continuation     = new PrtContinuation();
     this.currentTrigger   = PrtValue.@null;
     this.currentPayload   = PrtValue.@null;
     this.currentStatus    = PrtMachineStatus.Enabled;
     this.nextSMOperation  = PrtNextStatemachineOperation.ExecuteFunctionOperation;
     this.stateExitReason  = PrtStateExitReason.NotExit;
     this.sends            = new List <PrtEventValue>();
     this.stateImpl        = null;
     this.renamedName      = null;
     this.isSafe           = false;
 }