ToSourceBindingExpression<TSource, TValue>

A source-only binding that can optionally convert the incoming control value.
public sealed class ToSourceBindingExpression<TSource, TValue> : BindingExpression<TValue?> where TSource : class
Type parameterSummary
(class) TSourceThe root binding source type.
TValueThe source value type.

Methods

ConvertFrom

Converts an incoming control value before writing it to the source.

public WritableBindingExpression<TTarget?> ConvertFrom<TTarget>(
  Func<TTarget?, TValue> convert)
ParameterSummary
Func<TTarget?, TValue> convertConverts nullable control values to source values.
Type parameterSummary
TTargetThe control value type.

Returns

UpdateOn

Chooses when control changes are written to the source.

public WritableBindingExpression<TValue?> UpdateOn(
  UpdateTrigger trigger)
ParameterSummary
UpdateTrigger triggerWhen to write control changes.

Returns