次の方法で共有


PolicyStore.SubscribeToPolicyCategory(SfcQueryExpression, String) Method

Definition

Creates a subscription for the provided target to the specified policy category. This will throw if the subscription already exists.

public Microsoft.SqlServer.Management.Dmf.PolicyCategorySubscription SubscribeToPolicyCategory (Microsoft.SqlServer.Management.Sdk.Sfc.SfcQueryExpression target, string policyCategory);
member this.SubscribeToPolicyCategory : Microsoft.SqlServer.Management.Sdk.Sfc.SfcQueryExpression * string -> Microsoft.SqlServer.Management.Dmf.PolicyCategorySubscription
Public Function SubscribeToPolicyCategory (target As SfcQueryExpression, policyCategory As String) As PolicyCategorySubscription

Parameters

target
SfcQueryExpression

An expression that SfcObjectQuery will evaluate to a specific instance.

policyCategory
String

The category name to subscribe to.

Returns

PolicyCategorySubscription

Applies to