Sdílet prostřednictvím


BinderBase<T>.IValueSource.TryGetValue Metoda

Definice

Pokusí se získat hodnotu z kontextu vazby. Vrácená hodnota označuje, jestli byla přítomna hodnota odpovídající zadanému popisovači hodnot.

 virtual bool System.CommandLine.Binding.IValueSource.TryGetValue(System::CommandLine::Binding::IValueDescriptor ^ valueDescriptor, System::CommandLine::Binding::BindingContext ^ bindingContext, [Runtime::InteropServices::Out] System::Object ^ % boundValue) = System::CommandLine::Binding::IValueSource::TryGetValue;
bool IValueSource.TryGetValue (System.CommandLine.Binding.IValueDescriptor valueDescriptor, System.CommandLine.Binding.BindingContext? bindingContext, out object? boundValue);
abstract member System.CommandLine.Binding.IValueSource.TryGetValue : System.CommandLine.Binding.IValueDescriptor * System.CommandLine.Binding.BindingContext * obj -> bool
override this.System.CommandLine.Binding.IValueSource.TryGetValue : System.CommandLine.Binding.IValueDescriptor * System.CommandLine.Binding.BindingContext * obj -> bool
Function TryGetValue (valueDescriptor As IValueDescriptor, bindingContext As BindingContext, ByRef boundValue As Object) As Boolean Implements IValueSource.TryGetValue

Parametry

valueDescriptor
IValueDescriptor

Popisovač hodnoty, která se má svázat.

bindingContext
BindingContext

Kontext vazby, ze kterého se má svázat hodnota.

boundValue
Object

Když tato metoda vrátí, obsahuje vázanou hodnotu.

Návraty

truepokud byla nalezena odpovídající hodnota; v opačném případě . false

Implementuje

Platí pro