NotificationClassProtocol を NotificationClassProtocolCollection に追加します。
名前空間: Microsoft.SqlServer.Management.Nmo
アセンブリ: Microsoft.SqlServer.Smo (microsoft.sqlserver.smo.dll 内)
構文
'宣言
Public Sub Add ( _
notificationClassProtocol As NotificationClassProtocol _
)
public void Add (
NotificationClassProtocol notificationClassProtocol
)
public:
void Add (
NotificationClassProtocol^ notificationClassProtocol
)
public void Add (
NotificationClassProtocol notificationClassProtocol
)
public function Add (
notificationClassProtocol : NotificationClassProtocol
)
パラメータ
- notificationClassProtocol
コレクションに追加する NotificationClassProtocol です。
解説
配置したアプリケーションに配信プロトコルを追加した場合、インスタンスを更新すると、対応する通知クラスが削除されて再作成されます。同時に、この通知クラスが使用していたテーブルも削除され、再作成されます。元の Microsoft SQL Server テーブル内に存在するデータは、すべて完全に削除されます。
使用例
次の例は、NotificationClassProtocolCollection オブジェクト (ここでは NotificationClassProtocols プロパティによって返される) を使用して、通知クラスに配信プロトコルを追加する方法を示しています。
flightNotifications.NotificationClassProtocols.Add(smtpProtocol);
flightNotifications.NotificationClassProtocols.Add(smtpProtocol)
スレッド セーフ
この型の public static (Microsoft Visual Basic では共有 ) メンバは、スレッド セーフです。インスタンス メンバの場合は、スレッド セーフであるとは限りません。
プラットフォーム
開発プラットフォーム
サポートされているプラットフォームの一覧については、「SQL Server 2005 のインストールに必要なハードウェアおよびソフトウェア」を参照してください。
対象プラットフォーム
サポートされているプラットフォームの一覧については、「SQL Server 2005 のインストールに必要なハードウェアおよびソフトウェア」を参照してください。
参照
関連項目
NotificationClassProtocolCollection Class
NotificationClassProtocolCollection Members
Microsoft.SqlServer.Management.Nmo Namespace