Поделиться через


Класс LogProvider

Contains information about a log provider associated with a package. All log providers associated with a package are located in the LogProviders collection. For log providers on the computer, use the Application class and view the LogProviderInfos collection. This class cannot be inherited.

Иерархия наследования

System. . :: . .Object
  Microsoft.SqlServer.Dts.Runtime. . :: . .DtsObject
    Microsoft.SqlServer.Dts.Runtime..::..LogProvider

Пространство имен:  Microsoft.SqlServer.Dts.Runtime
Сборка:  Microsoft.SqlServer.ManagedDTS (в Microsoft.SqlServer.ManagedDTS.dll)

Синтаксис

'Декларация
Public NotInheritable Class LogProvider _
    Inherits DtsObject _
    Implements IDTSObjectHost, IDTSName, IDTSPersist, IDTSPropertiesProvider,  _
    IComponent, IDisposable, IDTSPackagePath
'Применение
Dim instance As LogProvider
public sealed class LogProvider : DtsObject, 
    IDTSObjectHost, IDTSName, IDTSPersist, IDTSPropertiesProvider, IComponent, 
    IDisposable, IDTSPackagePath
public ref class LogProvider sealed : public DtsObject, 
    IDTSObjectHost, IDTSName, IDTSPersist, IDTSPropertiesProvider, IComponent, 
    IDisposable, IDTSPackagePath
[<SealedAttribute>]
type LogProvider =  
    class
        inherit DtsObject
        interface IDTSObjectHost
        interface IDTSName
        interface IDTSPersist
        interface IDTSPropertiesProvider
        interface IComponent
        interface IDisposable
        interface IDTSPackagePath
    end
public final class LogProvider extends DtsObject implements IDTSObjectHost, IDTSName, IDTSPersist, IDTSPropertiesProvider, IComponent, IDisposable, IDTSPackagePath

Тип LogProvider обеспечивает доступ к следующим элементам.

Свойства

  Имя Описание
Открытое свойство ConfigString Gets or sets the connection and configuration information for the specific log provider.
Открытое свойство CreationName Returns the string used by the runtime to create an instance of the LogProvider object. This property is read-only.
Открытое свойство DelayValidation Gets or sets a Boolean that specifies whether a call to Validate for the log provider is delayed until package execution.
Открытое свойство Description Gets or sets the description of the LogProvider object.
Открытое свойство HostType Gets an enumeration that describes the type of host that the log provider is being used by. This property is read-only
Открытое свойство ID Gets the ID of the LogProvider. This property is read-only.
Открытое свойство InnerObject Returns the specific log provider that is being hosted by the LogProvider object.
Открытое свойство Name Gets or sets a the name of the LogProvider object, such as "SSIS log provider for Text files". This string is the text that shows in the Configure SSIS Logs (Providers and Logs Tab) dialog box in the Provider type drop-down menu.
Открытое свойство Properties Returns a DtsProperties collection, which contains a collection of DtsProperty objects.
Открытое свойство Site Инфраструктура.

В начало

Методы

  Имя Описание
Открытый метод CloseLog Closes the log.
Открытый метод Dispose Releases the resources used by the log provider.
Открытый метод Equals Determines whether two object instances are equal. (Производный от DtsObject.)
Защищенный метод Finalize (Производный от Object.)
Открытый метод GetExpression Returns a String that contains the expression for the specified property. Null means no expression is assigned.
Открытый метод GetHashCode Returns the hash code for this instance. (Производный от DtsObject.)
Открытый метод GetPackagePath Returns a String that contains the relative path to the package location.
Открытый метод GetType (Производный от Object.)
Открытый метод LoadFromXML This method is not callable by your application code. To load a package saved as .xml, use the Application..::..LoadPackage method.
Защищенный метод MemberwiseClone (Производный от Object.)
Открытый метод OpenLog Opens the log.
Открытый метод SaveToXML This method is not callable by your application code. To save a package as .xml, use the Application..::..SaveToXml method.
Открытый метод SetExpression Assigns the specified expression to the property. Specify nullNothingnullptrunitпустая ссылка (Nothing в Visual Basic) to remove an existing expression from the property.
Открытый метод ToString (Производный от Object.)

В начало

События

  Имя Описание
Открытое событие Disposed Adds an event handler to listen to the Disposed event on the log provider.

В начало

Замечания

The host log provider is a class that provides the methods and properties that are common to all of the log providers. Regardless of which log provider is in use, this class allows you to perform all tasks associated with logging. The LogProvider class is the object you use when programmatically adding log providers to a package. It is a generic host log provider that hosts an underlying log provider. The hosted log provider is accessible using the InnerObject. If you want to create a custom log provider, use the LogProviderBase class.

Безопасность многопоточности

Любые открытые статический (Shared в Visual Basic) элементы этого типа потокобезопасны. Потокобезопасность с элементами экземпляров не гарантируется.