IBotDataBag.TryGetValue<T>(String, T) Methode
Definition
Ruft den dem angegebenen Schlüssel zugeordneten Wert ab.Gets the value associated with the specified key.
public bool TryGetValue<T> (string key, out T value);
abstract member TryGetValue : string * 'T -> bool
Public Function TryGetValue(Of T) (key As String, ByRef value As T) As Boolean
Typparameter
- T
Der Typ des festzulegenden Werts.The type of the value to set.
Parameter
- key
- String
Der Schlüssel des abzurufenden Werts.The key of the value to get.
- value
- T
Wenn diese Methode zurückgegeben wird, enthält sie den Wert, der dem angegebenen Schlüssel zugeordnet ist, wenn der Schlüssel gefunden wurde, oder andernfalls den Standardwert für den Typ des Wertparameters.When this method returns, contains the value associated with the specified key, if the key is found; otherwise, the default value for the type of the value parameter. Dieser Parameter wird nicht initialisiert übergeben.This parameter is passed uninitialized.
Gibt zurück
true, wenn das IBotDataBag ein Element mit dem angegebenen Schlüssel enthält, andernfalls false.true if the IBotDataBag contains an element with the specified key; otherwise, false.