Beispiel #1
0
        static void RunMenu()
        {
            Console.WriteLine("What do you want to update?");
            string input = Console.ReadLine();

            switch (input)
            {
            case "products":
                ProductUpdater.Run();
                RunMenu();
                break;

            case "categories":
                CategoryUpdater.Run();
                RunMenu();
                break;

            case "promotions":
                break;

            case "all":
                ProductUpdater.Run();
                CategoryUpdater.Run();
                RunMenu();
                break;

            case "help":
                Console.WriteLine("- products");
                Console.WriteLine("- categories");
                Console.WriteLine("- all");
                RunMenu();
                break;

            default:
                Console.WriteLine("Unknown Command: Use 'help' for all available commands.");
                RunMenu();
                break;
            }
        }
Beispiel #2
0
 public CategoryData(string title, CategoryUpdater updater)
 {
     Title       = title;
     dataUpdater = updater;
 }