Example #1
0
        private void ExecuteCommand(string command)
        {
            this.history.Add(command);
            if (kernel.Execute(command))
            {
                return;
            }
            string sufix = completionTree.CompleteWord(command);

            if (!String.IsNullOrEmpty(sufix))
            {
                lock (ConsoleManager.ConsoleLock)
                {
                    Console.WriteLine("\tUnknown command. Did you meant: {0}{1}?", command, sufix);
                }
            }
        }
Example #2
0
        /// <summary>
        /// Keep running the application
        /// </summary>
        private void Run()
        {
            if (!LoadBlackboard())
            {
                return;
            }
            this.log.WriteLine("Starting Blackboard");
            this.blackboard.Start();
            Program.running = true;

            this.kernel         = new Kernel(blackboard);
            this.consoleManager = new ConsoleManager(blackboard, kernel, cLog);
            this.consoleManager.DisableLog();
            kernel.ListModules();
            kernel.Execute("help");
            consoleManager.WritePrompt();
            while (this.blackboard.IsRunning)
            {
                consoleManager.Poll();
            }
            Console.WriteLine("Good bye!");
            Console.WriteLine();
        }
Example #3
0
        /// <summary>
        /// Keep running the application
        /// </summary>
        private void Run()
        {
            if (!LoadBlackboard())
                return;
            this.log.WriteLine("Starting Blackboard");
            this.blackboard.Start();
            Program.running = true;

            this.kernel = new Kernel(blackboard);
            this.consoleManager = new ConsoleManager(blackboard, kernel, cLog);
            this.consoleManager.DisableLog();
            kernel.ListModules();
            kernel.Execute("help");
            consoleManager.WritePrompt();
            while (this.blackboard.IsRunning)
            {
                consoleManager.Poll();
            }
            Console.WriteLine("Good bye!");
            Console.WriteLine();
        }