NotificationClass.Parent Property
Gets or sets the Application object for the NotificationClass.
Пространство имен: Microsoft.SqlServer.Management.Nmo
Сборка: Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)
Синтаксис
'Декларация
Public Property Parent As Application
public Application Parent { get; set; }
public:
property Application^ Parent {
Application^ get ();
void set (Application^ value);
}
/** @property */
public Application get_Parent ()
/** @property */
public void set_Parent (Application value)
public function get Parent () : Application
public function set Parent (value : Application)
Значение свойства
The parent Application object for the NotificationClass object.
Замечания
Изменения текста5 декабря 2005 г.
Изменения образцов кода5 декабря 2005 г.
Each event class has a parent Application object. You typically provide the parent application object when you create the NotificationClass using the NotificationClass(Application,String) constructor.
If you set the parent in the constructor, do not set the parent using this property. Setting the parent twice throws an exception.
Пример
The following examples show how to set the Parent property when using the default constructor:
// Create a NotificationClass and define required properties
NotificationClass flightNotifications = new NotificationClass();
flightNotifications.Name = "FlightNotifications";
flightNotifications.Parent = myApplication;
flightNotifications.FileGroup = "PRIMARY";
flightNotifications.NotificationBatchSize = 0;
flightNotifications.DigestDelivery = false;
flightNotifications.MulticastDelivery = false;
flightNotifications.ExpirationAge = TimeSpan.Zero;
' Create a NotificationClass and define required properties
Dim flightNotifications As NotificationClass = New NotificationClass()
flightNotifications.Name = "FlightNotifications"
flightNotifications.Parent = myApplication
flightNotifications.FileGroup = "PRIMARY"
flightNotifications.NotificationBatchSize = 0
flightNotifications.DigestDelivery = False
flightNotifications.MulticastDelivery = False
flightNotifications.ExpirationAge = TimeSpan.Zero
Синхронизация потоков
Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Платформы
Платформы разработки
Список поддерживаемых платформ см. в разделе Hardware and Software Requirements for Installing SQL Server 2005.
Целевые платформы
Список поддерживаемых платформ см. в разделе Hardware and Software Requirements for Installing SQL Server 2005.
См. также
Справочник
NotificationClass Class
NotificationClass Members
Microsoft.SqlServer.Management.Nmo Namespace