예제 #1
0
파일: ReplTest.cs 프로젝트: vogon/nomic
        public void Initialize()
        {
            this._view = new View();

            IronPythonEvaluationContext lang = new IronPythonEvaluationContext();

            this._repl = new Repl(this._view, lang);
        }
예제 #2
0
파일: Program.cs 프로젝트: vogon/nomic
        private void ServeLocalInteraction()
        {
            while (!_shutdown)
            {
                IronPythonEvaluationContext lang = new IronPythonEvaluationContext();
                Repl repl = new Repl(new ConsoleReplView(), lang);

                // HACK: load static scripts so I have something to test
                repl.LoadScripts(_staticScripts);

                Task t = repl.Main();

                t.Wait();

                if (!_shutdown)
                {
                    Console.Out.WriteLine("!!! local interaction detached; restarting (server.Shutdown() to shut down server)...");
                }
            }
        }