public bool EndWaitForMessage(IAsyncResult result) { bool flag; this.ThrowIfNotOpened(); if (result == null) { throw Microsoft.ServiceBus.Diagnostics.DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("result"); } Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult doneReceivingAsyncResult = result as Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult; if (doneReceivingAsyncResult != null) { return(Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult.End(doneReceivingAsyncResult)); } bool flag1 = true; try { bool flag2 = this.messageSource.EndWaitForMessage(result); flag1 = !flag2; flag = flag2; } finally { if (flag1) { base.Fault(); } } return(flag); }
public Message EndReceive(IAsyncResult result) { Message message; this.ThrowIfNotOpened(); if (result == null) { throw Microsoft.ServiceBus.Diagnostics.DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("result"); } Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult doneReceivingAsyncResult = result as Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult; if (doneReceivingAsyncResult != null) { Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult.End(doneReceivingAsyncResult); return(null); } bool flag = true; Message message1 = null; try { message1 = this.messageSource.EndReceive(result); this.OnReceiveMessage(message1); flag = false; message = message1; } finally { if (flag) { if (message1 != null) { message1.Close(); message1 = null; } base.Fault(); } } return(message); }
internal static bool End(Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult result) { return(true); }
internal static bool End(Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult result, out RequestContext requestContext) { requestContext = null; return(true); }
internal static bool End(Microsoft.ServiceBus.Channels.DoneReceivingAsyncResult result, out Message message) { message = null; return(true); }