示例#1
0
 internal async Task WaitForMessageAsync()
 {
     try
     {
         await binder.WaitForMessageAsync(CancellationToken.None);
     }
     catch (CommunicationObjectAbortedException) { }
     catch (CommunicationObjectFaultedException) { }
     catch (CommunicationException e)
     {
         HandleError(e);
     }
     catch (Exception e)
     {
         if (Fx.IsFatal(e))
         {
             throw;
         }
         HandleErrorOrAbort(e);
     }
 }
示例#2
0
 public Task <bool> WaitForMessageAsync(CancellationToken token)
 {
     return(channelBinder.WaitForMessageAsync(token));
 }