IDTSDesigntimeComponent100 接口

定义

public interface class IDTSDesigntimeComponent100
[System.Runtime.InteropServices.Guid("FF5DD3F1-99C1-4FFB-B097-1B1B2B9E9B2D")]
[System.Runtime.InteropServices.TypeLibType(System.Runtime.InteropServices.TypeLibTypeFlags.FDispatchable | System.Runtime.InteropServices.TypeLibTypeFlags.FDual)]
public interface IDTSDesigntimeComponent100
[<System.Runtime.InteropServices.Guid("FF5DD3F1-99C1-4FFB-B097-1B1B2B9E9B2D")>]
[<System.Runtime.InteropServices.TypeLibType(System.Runtime.InteropServices.TypeLibTypeFlags.FDispatchable | System.Runtime.InteropServices.TypeLibTypeFlags.FDual)>]
type IDTSDesigntimeComponent100 = interface
Public Interface IDTSDesigntimeComponent100
派生
属性

示例

以下代码示例演示了如何访问组件的设计时实例。

Package p = new Package();  
MainPipe dataFlow = ((TaskHost)p.Executables.Add("DTS.Pipeline")).InnerObject as MainPipe;  

IDTSComponentMetaData100 md = dataFlow.ComponentMetaDataCollection.New();  
md.ComponentClassID = "DTSAdapter.OleDbSource";  
CManagedComponentWrapper wrp = md.Instantiate();  
wrp.ProvideComponentProperties();  
Dim p As Package = New Package   
Dim dataFlow As MainPipe = CType(CType(p.Executables.Add("DTS.Pipeline"), TaskHost).InnerObject, MainPipe)   
Dim md As IDTSComponentMetaData100 = dataFlow.ComponentMetaDataCollection.New   
md.ComponentClassID = "DTSAdapter.OleDbSource"   
Dim wrp As CManagedComponentWrapper = md.Instantiate   
wrp.ProvideComponentProperties  

注解

该接口是由数据流组件实现的两个接口之一;IDTSRuntimeComponent100 是另一个。 该接口定义了组件的设计时接口,并包含在修改组件属性和组件元数据集合时调用的方法。 托管组件开发者不显式实现该接口,而是使用 PipelineComponent 基类,该类实现了这两个接口的方法。

在程序性添加或修改数据流任务中的现有组件时,应使用组件的设计时实例,而非直接访问组件元数据。 直接修改组件元数据会绕过组件验证和拒绝元数据变更的能力,因此应避免。 托管代码开发者通过 CManagedComponentWrapper 访问组件的设计时实例,并使用 IDTSDesigntimeComponent100 接口的方法。

适用于