BrokerPriority.ContractName 属性

Gets or sets the contract name specified for the BrokerPriority object.

此 API 不符合 CLS。 

命名空间:  Microsoft.SqlServer.Management.Smo.Broker
程序集:  Microsoft.SqlServer.Smo(在 Microsoft.SqlServer.Smo.dll 中)

语法

声明
<SfcPropertyAttribute(SfcPropertyFlags.Standalone)> _
<CLSCompliantAttribute(False)> _
<SfcReferenceAttribute(GetType(ServiceContract), "Server[@Name = '{0}']/Database[@Name = '{1}']/ServiceBroker/ServiceContract[@Name='{2}']",  _
    )> _
Public Property ContractName As String 
    Get 
    Set
用法
Dim instance As BrokerPriority 
Dim value As String 

value = instance.ContractName

instance.ContractName = value
[SfcPropertyAttribute(SfcPropertyFlags.Standalone)]
[CLSCompliantAttribute(false)]
[SfcReferenceAttribute(typeof(ServiceContract), "Server[@Name = '{0}']/Database[@Name = '{1}']/ServiceBroker/ServiceContract[@Name='{2}']", 
    )]
public string ContractName { get; set; }
[SfcPropertyAttribute(SfcPropertyFlags::Standalone)]
[CLSCompliantAttribute(false)]
[SfcReferenceAttribute(typeof(ServiceContract), L"Server[@Name = '{0}']/Database[@Name = '{1}']/ServiceBroker/ServiceContract[@Name='{2}']", 
    )]
public:
property String^ ContractName {
    String^ get ();
    void set (String^ value);
}
[<SfcPropertyAttribute(SfcPropertyFlags.Standalone)>]
[<CLSCompliantAttribute(false)>]
[<SfcReferenceAttribute(typeof(ServiceContract), "Server[@Name = '{0}']/Database[@Name = '{1}']/ServiceBroker/ServiceContract[@Name='{2}']", 
    )>]
member ContractName : string with get, set
function get ContractName () : String 
function set ContractName (value : String)

属性值

类型:System.String
A String value that specifies the name of a Service Broker contract to be used as a criterion for determining if the conversation priority applies to a conversation.

注释

If ANY is specified for the contract name, the conversation priority can be applied to any conversation, regardless of which contract it uses. If the name of a contract is specified, the conversation priority can be applied only to conversations where the BEGIN DIALOG statement that started the conversation specified ON CONTRACT ContractName. ContractName must specify a contract in the current database.

The ContractName default is ANY.

示例

CREATE BROKER PRIORITY (Transact-SQL)

请参阅

参考

BrokerPriority 类

Microsoft.SqlServer.Management.Smo.Broker 命名空间

其他资源

会话优先级

管理会话优先级

排除会话优先级的故障

开发 (Service Broker)

概述 (Service Broker)

CREATE BROKER PRIORITY (Transact-SQL)

ALTER BROKER PRIORITY (Transact-SQL)