Condividi tramite


Application.NonHostedEventProviders Property

Gets a NonHostedEventProviderCollection object, which contains the set of non-hosted event providers for the Notification Services application.

Spazio dei nomi: Microsoft.SqlServer.Management.Nmo
Assembly : Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)

Sintassi

'Dichiarazione
Public ReadOnly Property NonHostedEventProviders As NonHostedEventProviderCollection
public NonHostedEventProviderCollection NonHostedEventProviders { get; }
public:
property NonHostedEventProviderCollection^ NonHostedEventProviders {
    NonHostedEventProviderCollection^ get ();
}
/** @property */
public NonHostedEventProviderCollection get_NonHostedEventProviders ()
public function get NonHostedEventProviders () : NonHostedEventProviderCollection

Valore proprietà

A NonHostedEventProviderCollection object.

Osservazioni

Non-hosted event providers are independent event collection components; they are not run by the Notification Services engine. They are usually independent applications that use the Notification Services API or stored procedure to submit event data to an application. You declare the non-hosted event providers so you can later troubleshoot and track event collection. An application can have zero or more non-hosted event providers. An application can also use hosted event providers.

Use the methods of the NonHostedEventProviderCollection class to add or remove NonHostedEventProvider objects.

Esempio

The following example shows how to define a non-hosted event provider and add it to an application:

// Define non-hosted event provider
NonHostedEventProvider nhep = 
    new NonHostedEventProvider(myApplication, "MyNonHostedEP");
myApplication.NonHostedEventProviders.Add(nhep);
' Define non-hosted event provider
Dim nhep As NonHostedEventProvider = _
    New NonHostedEventProvider(myApplication, "MyNonHostedEP")
myApplication.NonHostedEventProviders.Add(nhep)

Thread Safety

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.

Piattaforme

Piattaforme di sviluppo

Per un elenco delle piattaforme supportate, vedere Requisiti hardware e software per l'Installazione di SQL Server 2005.

Piattaforme di destinazione

Per un elenco delle piattaforme supportate, vedere Requisiti hardware e software per l'Installazione di SQL Server 2005.

Vedere anche

Riferimento

Application Class
Application Members
Microsoft.SqlServer.Management.Nmo Namespace
Application.HostedEventProviders Property

Altre risorse

Definizione di provider di eventi
Sviluppo di provider di eventi non hosted