예제 #1
0
파일: Menu.cs 프로젝트: talmartin/pa1
        public static void Option1(List <Posts> posts)
        {
            Console.Clear();
            Console.WriteLine("");
            PostUtility.SortAllPosts(posts);
            PostUtility.DisplayAllPosts(posts);
            Console.WriteLine("\nHere is a list of all posts sorted by most recent.\nPress a key to return to the main menu.\n");

            Console.ReadKey();
            Console.Clear();
        }
예제 #2
0
파일: Menu.cs 프로젝트: talmartin/pa1
        public static void Option3(List <Posts> posts)
        {
            Console.Clear();
            Console.WriteLine("");
            PostUtility.SortAllPosts(posts);
            PostUtility.DisplayAllPosts(posts);

            Console.WriteLine("\nHere is a list of all posts sorted by most recent.\nPlease input a post ID to delete that post.");
            PostUtility.DeletePost(posts);
            Console.WriteLine("");

            PostUtility.SortAllPosts(posts);
            PostUtility.DisplayAllPosts(posts);
        }
예제 #3
0
파일: Menu.cs 프로젝트: talmartin/pa1
        public static void Option2(List <Posts> posts)
        {
            Console.Clear();
            Console.WriteLine("");
            PostUtility.SortAllPosts(posts);
            PostUtility.DisplayAllPosts(posts);

            Console.WriteLine("\nHere is a list of all posts sorted by most recent.\nType out a post and hit enter to upload it!\n");
            PostUtility.AddPost(posts);
            Console.WriteLine("");

            PostUtility.SortAllPosts(posts);
            PostUtility.DisplayAllPosts(posts);
        }