英語で読む

次の方法で共有


MethodBuilder.DefineParameterCore(Int32, ParameterAttributes, String) メソッド

定義

派生クラスでオーバーライドされた場合、このメソッドのパラメーターまたは戻り値パラメーターを定義します。

C#
protected abstract System.Reflection.Emit.ParameterBuilder DefineParameterCore(int position, System.Reflection.ParameterAttributes attributes, string? strParamName);

パラメーター

position
Int32

パラメーター リストのパラメーターの位置。 パラメーターには、最初のパラメーターの数値 1 から始まるインデックスが作成されます。数値 0 は、 メソッドの戻り値パラメーターを表します。

attributes
ParameterAttributes

パラメーターの ParameterAttributes

strParamName
String

パラメーターの名前。 名前には文字列を null 指定できます。

戻り値

このメソッドの ParameterBuilder パラメーターまたはこのメソッドの戻り値パラメーターを表す オブジェクトを返します。

注釈

返される ParameterBuilder を使用して、カスタム属性を適用できます。

適用対象

製品 バージョン
.NET 8, 9, 10