NamespaceManager.GetSubscriptions Method

Definition

Overloads

GetSubscriptions(String)

Retrieves an enumerable collection of all subscriptions in the service namespace.

GetSubscriptions(String, String)

Retrieves an enumerable collection of all subscriptions in the service namespace with specified topic path and filter.

GetSubscriptions(String)

Retrieves an enumerable collection of all subscriptions in the service namespace.

public System.Collections.Generic.IEnumerable<Microsoft.ServiceBus.Messaging.SubscriptionDescription> GetSubscriptions (string topicPath);
member this.GetSubscriptions : string -> seq<Microsoft.ServiceBus.Messaging.SubscriptionDescription>
Public Function GetSubscriptions (topicPath As String) As IEnumerable(Of SubscriptionDescription)

Parameters

topicPath
String

The path of the topic relative to the service namespace base address.

Returns

An IEnumerable<T> object that represents the collection of all subscriptions in the service namespace or returns an empty collection if no subscription exists.

Applies to

GetSubscriptions(String, String)

Retrieves an enumerable collection of all subscriptions in the service namespace with specified topic path and filter.

public System.Collections.Generic.IEnumerable<Microsoft.ServiceBus.Messaging.SubscriptionDescription> GetSubscriptions (string topicPath, string filter);
member this.GetSubscriptions : string * string -> seq<Microsoft.ServiceBus.Messaging.SubscriptionDescription>
Public Function GetSubscriptions (topicPath As String, filter As String) As IEnumerable(Of SubscriptionDescription)

Parameters

topicPath
String

The path of the topic relative to the service namespace base address.

filter
String

The string used to filter the subscriptions to be retrieved.

Returns

An IEnumerable<T> object that represents the collection of all subscriptions in the service namespace or returns an empty collection if no subscription exists.

Examples

var subscriptionsWithMessages = namespaceManager.GetSubscriptions("topicName", "messageCount Gt 0");
var subscriptionsStartsWith = namespaceManager.GetSubscriptions("topicName", $"startswith(path, 'subscription') eq true");

Remarks

Filter expression formats: {Propery} {Logical Operator} {Value} AND {Filter expression} {Function} {Logical Operator} {Value} AND {Filter expression} ----------------------------------------------------------------------------------------- Available properties: ModifiedAt | AccessedAt | CreatedAt | MessageCount Logical operators: Eq | Ne | Gt | Ge | Lt | Le Value: A value of the corresponding property type Functions: startswith({Propery}, {Value})

Applies to