public ProcessBaseCore()
		{
			//Console.WriteLine(this + " : " + parent);

			Impl = ProcessBaseImplFactory();
			State = State.Started;

			Impl.Init(() =>
			{
				Action method = Main;

			restart:
				try
				{
					State = State.Running;
					method();
					State = State.Ended;
					Yield();
				}
				catch (ChangeExecutionMethodException ChangeExecutionMethodException)
				{
					method = ChangeExecutionMethodException.method;
					goto restart;
				}
			});
		}
Exemple #2
0
        public ProcessBaseCore()
        {
            //Console.WriteLine(this + " : " + parent);

            Impl  = ProcessBaseImplFactory();
            State = State.Started;

            Impl.Init(() =>
            {
                Action method = Main;

                restart:
                try
                {
                    State = State.Running;
                    method();
                    State = State.Ended;
                    Yield();
                }
                catch (ChangeExecutionMethodException ChangeExecutionMethodException)
                {
                    method = ChangeExecutionMethodException.method;
                    goto restart;
                }
            });
        }
Exemple #3
0
        public ProcessBase()
        {
            //Console.WriteLine(this + " : " + parent);

            Impl  = (IProcessBaseImpl)Activator.CreateInstance(ProcessBaseImplType);
            State = State.Started;

            Impl.Init(() =>
            {
                State = State.Running;
                main();
                State = State.Ended;
                Yield();
            });
        }