/// <summary> /// Gets the set of connection strings for a topic. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.WindowsAzure.Management.ServiceBus.ITopicOperations. /// </param> /// <param name='namespaceName'> /// The namespace name. /// </param> /// <param name='topicName'> /// The topic. /// </param> /// <returns> /// The set of connection details for a service bus entity. /// </returns> public static ServiceBusConnectionDetailsResponse GetConnectionDetails(this ITopicOperations operations, string namespaceName, string topicName) { try { return(operations.GetConnectionDetailsAsync(namespaceName, topicName).Result); } catch (AggregateException ex) { if (ex.InnerExceptions.Count > 1) { throw; } else { throw ex.InnerException; } } }
/// <summary> /// Gets the set of connection strings for a topic. /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.WindowsAzure.Management.ServiceBus.ITopicOperations. /// </param> /// <param name='namespaceName'> /// Required. The namespace name. /// </param> /// <param name='topicName'> /// Required. The topic. /// </param> /// <returns> /// The set of connection details for a service bus entity. /// </returns> public static Task <ServiceBusConnectionDetailsResponse> GetConnectionDetailsAsync(this ITopicOperations operations, string namespaceName, string topicName) { return(operations.GetConnectionDetailsAsync(namespaceName, topicName, CancellationToken.None)); }