Язык

IValueSource.TryGetValue(IValueDescriptor, BindingContext, Object) Метод

Определение

Возвращает значение из контекста привязки. Возвращаемое значение указывает, присутствует ли значение, соответствующее указанному дескриптору значений.

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

Параметры

valueDescriptor
IValueDescriptor

Дескриптор для ограничивающего значения.

bindingContext
BindingContext

Контекст привязки, из которого необходимо привязать значение.

boundValue
Object

Привязанное значение.

Возвращаемое значение

true Значение, соответствующее значение; falseв противном случае .

Применяется к