Files
2024-10-01 00:55:06 +03:00

26 lines
561 B
C#

using CommandHandler;
using CommandHandler.Navigation;
using CommandHandler.Navigation.States;
Console.WriteLine("Hello, World!");
INavigationContext context = new NavigationContext();
context.SetState(new NavigationMainState());
while (ApplicationContext.IsRan)
{
try
{
var line = Console.ReadLine();
if (!string.IsNullOrEmpty(line))
{
var command = context.GetCommand(line);
await command.Execute();
}
}
catch (Exception ex)
{
Console.WriteLine(ex.ToString());
}
}