CManagedComponentWrapper Interface
コンポーネントのプロパティと列コレクションを構成します。
名前空間: Microsoft.SqlServer.Dts.Pipeline.Wrapper
アセンブリ: Microsoft.SqlServer.DTSPipelineWrap (microsoft.sqlserver.dtspipelinewrap.dll 内)
構文
'宣言
<CoClassAttribute(GetType(CManagedComponentWrapperClass))> _
<GuidAttribute("76F19268-BCE0-4A23-95D1-F85AC738941D")> _
Public Interface CManagedComponentWrapper
Inherits IDTSDesigntimeComponent90
[CoClassAttribute(typeof(CManagedComponentWrapperClass))]
[GuidAttribute("76F19268-BCE0-4A23-95D1-F85AC738941D")]
public interface CManagedComponentWrapper : IDTSDesigntimeComponent90
[CoClassAttribute(typeof(CManagedComponentWrapperClass))]
[GuidAttribute(L"76F19268-BCE0-4A23-95D1-F85AC738941D")]
public interface class CManagedComponentWrapper : IDTSDesigntimeComponent90
/** @attribute CoClassAttribute(Microsoft.SqlServer.Dts.Pipeline.Wrapper.CManagedComponentWrapperClass) */
/** @attribute GuidAttribute("76F19268-BCE0-4A23-95D1-F85AC738941D") */
public interface CManagedComponentWrapper extends IDTSDesigntimeComponent90
CoClassAttribute(Microsoft.SqlServer.Dts.Pipeline.Wrapper.CManagedComponentWrapperClass)
GuidAttribute("76F19268-BCE0-4A23-95D1-F85AC738941D")
public interface CManagedComponentWrapper extends IDTSDesigntimeComponent90
解説
CManagedComponentWrapper は、デザイン時のデータ フロー コンポーネントの変更で使用される IDTSDesigntimeComponent90 のインターフェイスを表します。CManagedComponentWrapper は、デザイン時にデータ フロー コンポーネントのプロパティと列コレクションを構成するために使用されます。コンポーネントのメタデータを直接変更することはできますが、このようにすると、メタデータに対する変更を検証するコンポーネントの機能がバイパスされるので、変更は直接行わないようにする必要があります。CManagedComponentWrapper のインスタンスは、コンポーネントの IDTSComponentMetaData90 インターフェイスの Instantiate メソッドを呼び出すことで作成されます。
このインターフェイスによって定義されるメソッドとプロパティは、CManagedComponentWrapperClass と IDTSDesigntimeComponent90 の両方の種類で表示されます。
使用例
次のコード例では、プログラムでデータ フロー タスクにコンポーネントを追加し、デザイン時インターフェイスのインスタンスを作成する方法を示します。
using System;
using Microsoft.SqlServer.Dts.Runtime;
using Microsoft.SqlServer.Dts.Pipeline.Wrapper;
namespace Microsoft.Samples.SqlServer.Dts
{
class CreateComponent
{
[STAThread]
static void Main(string[] args)
{
// Create the package.
Package p = new Package();
// Add the data flow task to the package.
MainPipe dataFlowTask = ((TaskHost)p.Executables.Add("DTS.Pipeline.1")).InnerObject as MainPipe;
if (dataFlowTask != null)
{
// Add a component to the data flow task.
IDTSComponentMetaData90 metaData = dataFlowTask.ComponentMetaDataCollection.New();
// Set the class id of the component.
metaData.ComponentClassID = "";
// Create an instance of the component.
CManagedComponentWrapper wrapper = metaData.Instantiate();
// Initialize the component by calling ProvideComponentProperties.
wrapper.ProvideComponentProperties();
}
}
}
}
プラットフォーム
開発プラットフォーム
サポートされているプラットフォームの一覧については、「SQL Server 2005 のインストールに必要なハードウェアおよびソフトウェア」を参照してください。
対象プラットフォーム
サポートされているプラットフォームの一覧については、「SQL Server 2005 のインストールに必要なハードウェアおよびソフトウェア」を参照してください。
参照
関連項目
CManagedComponentWrapper Members
Microsoft.SqlServer.Dts.Pipeline.Wrapper Namespace