Example #1
0
        private static void GetImageThumbnailTest(ImgurUtils imgur)
        {
            try
            {
                Console.WriteLine("\n=================================================\n" +
                                  "    Get the link for an image's thumbnail" +
                                  "\n=================================================\n");
                Console.WriteLine("Please type an image ID: ");
                var id = Console.ReadLine();

                Console.WriteLine("\nWhat size thumbnail? (small, medium, large, huge, small square, big square)");
                var thumb = Console.ReadLine();

                Console.WriteLine("\n" + imgur.GetImage(id).GetThumbnail(ThumbSizes[thumb]));
            }
            catch (Exception ex)
            {
                Console.WriteLine("\nERROR: " + ex.Message);
            }
        }
Example #2
0
 private static void GetImageTest(ImgurUtils imgur)
 {
     try
     {
         Console.WriteLine("\n=================================================\n" +
                           "    Get information about an existing image" +
                           "\n=================================================\n");
         Console.WriteLine("Please type an image ID: ");
         DumpImageInfo(imgur.GetImage(Console.ReadLine()));
     }
     catch (Exception ex)
     {
         Console.WriteLine("\nERROR: " + ex.Message);
     }
 }