From d1411b205c93034e722bbb46c6e0e323e2ecf701 Mon Sep 17 00:00:00 2001 From: Steve Rao Date: Wed, 23 Oct 2019 06:45:42 +0800 Subject: [PATCH] examples: adjust comment (#6314) --- .../main/java/io/grpc/examples/advanced/HelloJsonClient.java | 5 +++-- .../examples/experimental/CompressingHelloWorldClient.java | 5 +++-- .../java/io/grpc/examples/header/CustomHeaderClient.java | 5 +++-- .../java/io/grpc/examples/helloworld/HelloWorldClient.java | 5 +++-- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/examples/src/main/java/io/grpc/examples/advanced/HelloJsonClient.java b/examples/src/main/java/io/grpc/examples/advanced/HelloJsonClient.java index 9e7d5971f0..264fe76b7d 100644 --- a/examples/src/main/java/io/grpc/examples/advanced/HelloJsonClient.java +++ b/examples/src/main/java/io/grpc/examples/advanced/HelloJsonClient.java @@ -78,12 +78,13 @@ public final class HelloJsonClient { * greeting. */ public static void main(String[] args) throws Exception { + // Access a service running on the local machine on port 50051 HelloJsonClient client = new HelloJsonClient("localhost", 50051); try { - /* Access a service running on the local machine on port 50051 */ String user = "world"; + // Use the arg as the name to greet if provided if (args.length > 0) { - user = args[0]; /* Use the arg as the name to greet if provided */ + user = args[0]; } client.greet(user); } finally { diff --git a/examples/src/main/java/io/grpc/examples/experimental/CompressingHelloWorldClient.java b/examples/src/main/java/io/grpc/examples/experimental/CompressingHelloWorldClient.java index 2ed51a48c1..410b0c7c14 100644 --- a/examples/src/main/java/io/grpc/examples/experimental/CompressingHelloWorldClient.java +++ b/examples/src/main/java/io/grpc/examples/experimental/CompressingHelloWorldClient.java @@ -73,12 +73,13 @@ public class CompressingHelloWorldClient { * greeting. */ public static void main(String[] args) throws Exception { + // Access a service running on the local machine on port 50051 CompressingHelloWorldClient client = new CompressingHelloWorldClient("localhost", 50051); try { - /* Access a service running on the local machine on port 50051 */ String user = "world"; + // Use the arg as the name to greet if provided if (args.length > 0) { - user = args[0]; /* Use the arg as the name to greet if provided */ + user = args[0]; } client.greet(user); } finally { diff --git a/examples/src/main/java/io/grpc/examples/header/CustomHeaderClient.java b/examples/src/main/java/io/grpc/examples/header/CustomHeaderClient.java index 1095c73e71..93d106dba9 100644 --- a/examples/src/main/java/io/grpc/examples/header/CustomHeaderClient.java +++ b/examples/src/main/java/io/grpc/examples/header/CustomHeaderClient.java @@ -75,12 +75,13 @@ public class CustomHeaderClient { * Main start the client from the command line. */ public static void main(String[] args) throws Exception { + // Access a service running on the local machine on port 50051 CustomHeaderClient client = new CustomHeaderClient("localhost", 50051); try { - /* Access a service running on the local machine on port 50051 */ String user = "world"; + // Use the arg as the name to greet if provided if (args.length > 0) { - user = args[0]; /* Use the arg as the name to greet if provided */ + user = args[0]; } client.greet(user); } finally { diff --git a/examples/src/main/java/io/grpc/examples/helloworld/HelloWorldClient.java b/examples/src/main/java/io/grpc/examples/helloworld/HelloWorldClient.java index 760f77c3bb..322c0f25f7 100644 --- a/examples/src/main/java/io/grpc/examples/helloworld/HelloWorldClient.java +++ b/examples/src/main/java/io/grpc/examples/helloworld/HelloWorldClient.java @@ -70,12 +70,13 @@ public class HelloWorldClient { * greeting. */ public static void main(String[] args) throws Exception { + // Access a service running on the local machine on port 50051 HelloWorldClient client = new HelloWorldClient("localhost", 50051); try { - /* Access a service running on the local machine on port 50051 */ String user = "world"; + // Use the arg as the name to greet if provided if (args.length > 0) { - user = args[0]; /* Use the arg as the name to greet if provided */ + user = args[0]; } client.greet(user); } finally {