예제 #1
0
        public static string deleteBlog(BlogService.BlogServiceClient client)
        {
            var response = client.DeleteBlog(new DeleteBlogRequest()
            {
                BlogId = "5f9f0f21a772b24eadb150a8"
            });

            return("new Blog" + response.BlogId + "was Deleted !");
        }
예제 #2
0
 private static void DeleteBlog(BlogService.BlogServiceClient client, Blog.Blog blog)
 {
     try
     {
         var response = client.DeleteBlog(new DeleteBlogRequest()
         {
             BlogId = blog.Id
         });
         Console.WriteLine($"The blog with id {response.BlogId} was deleted.");
     }
     catch (RpcException e)
     {
         Console.WriteLine(e.Status.Detail);
     }
 }
예제 #3
0
 private static void DeleteBlog(BlogService.BlogServiceClient client, Blog.Blog blog)
 {
     try
     {
         var response = client.DeleteBlog(new DeleteBlogrequest()
         {
             BlogId = blog.Id
         });
         Console.WriteLine("The blog id " + blog.Id + " is deleted");
     }
     catch (RpcException ex)
     {
         Console.WriteLine(ex.Status.Detail);
     }
 }
예제 #4
0
        private static void DeleteBlog(BlogService.BlogServiceClient client)
        {
            try
            {
                var response = client.DeleteBlog(new DeleteBlogRequest()
                {
                    BlogId = "5e91e157d31ecb45c8f84714"
                });

                Console.WriteLine("The blog with id " + response.BlogId + " was deleted");
            }
            catch (RpcException e)
            {
                Console.WriteLine(e.Status.Detail);
            }
        }