次の方法で共有


ModelFactory.CreateItem メソッド (EditingContext, TypeIdentifier, CreateOptions, array<Object )

指定した型識別子の新しいモデル アイテムを作成します。

名前空間:  Microsoft.Windows.Design.Model
アセンブリ:  Microsoft.Windows.Design.Interaction (Microsoft.Windows.Design.Interaction.dll 内)

構文

'宣言
Public Shared Function CreateItem ( _
    context As EditingContext, _
    typeIdentifier As TypeIdentifier, _
    options As CreateOptions, _
    ParamArray arguments As Object() _
) As ModelItem
public static ModelItem CreateItem(
    EditingContext context,
    TypeIdentifier typeIdentifier,
    CreateOptions options,
    params Object[] arguments
)
public:
static ModelItem^ CreateItem(
    EditingContext^ context, 
    TypeIdentifier typeIdentifier, 
    CreateOptions options, 
    ... array<Object^>^ arguments
)
static member CreateItem : 
        context:EditingContext * 
        typeIdentifier:TypeIdentifier * 
        options:CreateOptions * 
        arguments:Object[] -> ModelItem 
public static function CreateItem(
    context : EditingContext, 
    typeIdentifier : TypeIdentifier, 
    options : CreateOptions, 
    ... arguments : Object[]
) : ModelItem

パラメーター

  • arguments
    型: array<System.Object[]
    アイテムのコンストラクターに渡される引数の配列 (省略可能)。

戻り値

型: Microsoft.Windows.Design.Model.ModelItem
新しく作成されたアイテムの型を表す ModelItem。型識別子を解決できなかった場合、このメソッドは nullnull 参照 (Visual Basic では Nothing) を返す可能性があります。

例外

例外 条件
ArgumentNullException

context は nullnull 参照 (Visual Basic では Nothing) なので、

.NET Framework セキュリティ

  • 直前の呼び出し元に対する完全な信頼。 このメンバーは、部分的に信頼されているコードから使用することはできません。 詳細については、「部分信頼コードからのライブラリの使用」を参照してください。

参照

参照

ModelFactory クラス

CreateItem オーバーロード

Microsoft.Windows.Design.Model 名前空間

その他の技術情報

WPF デザイナーの機能拡張

編集モデルのアーキテクチャ