Skip to content

UriToStringTypeConverter.TryConvert(Uri?, object?, string?) method

Defined in

Type: UriToStringTypeConverter Namespace: ReactiveUI.Binding Assembly: ReactiveUI.Binding.dll

Applies to

net10.0, net10.0-browserwasm1.0, net10.0-desktop1.0, net9.0, net9.0-browserwasm1.0, net9.0-desktop1.0, net8.0, net8.0-ios17.5, net8.0-maccatalyst17.5, net8.0-macos14.2, net8.0-macos14.5, net8.0-tvos17.2, netstandard2.1, net462, net481

public override bool TryConvert(Uri? from, object? conversionHint, out string? result)

View source

Inherited documentation

These docs were inherited from BindingTypeConverter<Uri, string>. The member doesn't override them on this type.

Summary: Convert a value to the target type in a type-safe manner.

Parameters

NameTypeDescription
fromUri?The value to convert.
conversionHintobject?Implementation-defined hint for conversion (e.g., format string, locale).
out resultstring?The converted value. May be null when conversion succeeds for nullable targets.

Returns: bool -- true if conversion succeeded; otherwise, false.

Remarks

This method is AOT-safe as all types are known at compile time. No reflection or boxing is required for value types.

When this method returns true, the result parameter may still be null for converters that map null inputs or empty values to nullable targets.