次の方法で共有


Extensions.GetValue<T>(IBotDataBag, String) メソッド

定義

指定したキーに関連付けられている値を取得します。

public static T GetValue<T>(this Microsoft.Bot.Builder.Dialogs.IBotDataBag bag, string key);
static member GetValue : Microsoft.Bot.Builder.Dialogs.IBotDataBag * string -> 'T
<Extension()>
Public Function GetValue(Of T) (bag As IBotDataBag, key As String) As T

型パラメーター

T

取得する値の型。

パラメーター

bag
IBotDataBag

ボット データ バッグ。

key
String

取得または設定する値のキー。

戻り値

T

指定されたキーに関連付けられている値。 指定したキーが見つからない場合、get 操作は KeyNotFoundException をスローします。

例外

適用対象