示例#1
0
文件: Program.cs 项目: advi1012/AVG
 // Realisierung von FindAllPreferredSuppliers
 public async Task FindAllPreferredSuppliers()
 {
     Console.WriteLine("***** Task FindAllPreferredSuppliers *****");
     using (var call = _client.FindAllPreferredSuppliers(new Empty()))
     {
         int i = 1;
         while (await call.ResponseStream.MoveNext())
         {
             Console.WriteLine("***** Task FindAllPreferredSuppliers Iteration " + i + " *****");
             PreferredSupplier preferredSupplier = call.ResponseStream.Current;
             Console.WriteLine(i + " Received; preferred supplier: " + preferredSupplier.ToString());
             Console.WriteLine("***** Iteration " + i + " done *****");
             i++;
         }
     }
     Console.WriteLine("***** Task End *****");
 }