CodeObjectCreateExpression クラス
アセンブリ: System (system.dll 内)
 構文
構文<SerializableAttribute> _ <ClassInterfaceAttribute(ClassInterfaceType.AutoDispatch)> _ <ComVisibleAttribute(True)> _ Public Class CodeObjectCreateExpression Inherits CodeExpression
[SerializableAttribute] [ClassInterfaceAttribute(ClassInterfaceType.AutoDispatch)] [ComVisibleAttribute(true)] public class CodeObjectCreateExpression : CodeExpression
[SerializableAttribute] [ClassInterfaceAttribute(ClassInterfaceType::AutoDispatch)] [ComVisibleAttribute(true)] public ref class CodeObjectCreateExpression : public CodeExpression
 解説
解説CodeObjectCreateExpression を使用して、型のインスタンスを作成する式を表すことができます。
CreateType プロパティは、新しいインスタンスを作成するデータ型を指定します。Parameters プロパティは、新しいインスタンスを作成する型のコンストラクタに渡すパラメータを指定します。
 使用例
使用例CodeObjectCreateExpression と既定のコンストラクタを使用して、System.DateTime クラスの新しいインスタンスを作成する方法を次の例に示します。
Dim objectCreate1 As New CodeObjectCreateExpression("System.DateTime", New CodeExpression() {}) ' A Visual Basic code generator produces the following source code for the preceeding example code: ' New Date
CodeObjectCreateExpression objectCreate1 = new CodeObjectCreateExpression( "System.DateTime", new CodeExpression[] {} ); // A C# code generator produces the following source code for the preceeding example code: // new System.DateTime();
 継承階層
継承階層System.CodeDom.CodeObject
System.CodeDom.CodeExpression
System.CodeDom.CodeObjectCreateExpression
 スレッド セーフ
スレッド セーフ プラットフォーム
プラットフォームWindows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。
 バージョン情報
バージョン情報 参照
参照- CodeObjectCreateExpression クラスのページへのリンク

 
                             
                    


