Langue

EvaluationResult.TryGet<T>(String, T) Méthode

Définition

Retourne un EvaluationMetric avec type T et avec le Name via metricName spécifié s’il existe dans Metrics.

public:
generic <typename T>
 where T : Microsoft::Extensions::AI::Evaluation::EvaluationMetric bool TryGet(System::String ^ metricName, [Runtime::InteropServices::Out] T % value);
public bool TryGet<T>(string metricName, out T? value) where T : Microsoft.Extensions.AI.Evaluation.EvaluationMetric;
member this.TryGet : string * 'T -> bool (requires 'T :> Microsoft.Extensions.AI.Evaluation.EvaluationMetric)
Public Function TryGet(Of T As EvaluationMetric) (metricName As String, ByRef value As T) As Boolean

Paramètres de type

T

Type de la EvaluationMetric valeur à renvoyer.

Paramètres

metricName
String

À NameEvaluationMetric renvoyer.

value
T

Avec EvaluationMetric un type T et avec le Name via metricName spécifié s’il existe ; Metricsnull sinon.

Retours

truesi une correspondance value existe ; Metricsfalse sinon.

S’applique à