Skip to content

,System.Func{--0,--1},System.Collections.Generic.IEqualityComparer{--1},System.Threading.CancellationToken)} ,System.Func{--0,--1})} ,System.Func{--0,--1},System.Func{--0,--2},System.Collections.Generic.IEqualityComparer{--1},System.Threading.CancellationToken)} ,System.Func{--0,--1},System.Func{--0,--2})}

SignalAsyncExtensions.ToDictionaryAsync(IObservableAsync, Func, IEqualityComparer?, CancellationToken) method

Defined in

Type: SignalAsyncExtensions Namespace: ReactiveUI.Primitives.Async Assembly: ReactiveUI.Primitives.Async.dll

Applies to

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

Overloads

  • 1. public static ValueTask<Dictionary<TKey, T>> ToDictionaryAsync<T, TKey>(this IObservableAsync<T> @this, Func<T, TKey> keySelector, IEqualityComparer<TKey>? comparer, CancellationToken cancellationToken) where T : notnull where TKey : notnull
  • 2. public static ValueTask<Dictionary<TKey, T>> ToDictionaryAsync<T, TKey>(this IObservableAsync<T> @this, Func<T, TKey> keySelector) where T : notnull where TKey : notnull
  • 3. public static ValueTask<Dictionary<TKey, TValue>> ToDictionaryAsync<T, TKey, TValue>(this IObservableAsync<T> @this, Func<T, TKey> keySelector, Func<T, TValue> elementSelector, IEqualityComparer<TKey>? comparer, CancellationToken cancellationToken)
  • 4. public static ValueTask<Dictionary<TKey, TValue>> ToDictionaryAsync<T, TKey, TValue>(this IObservableAsync<T> @this, Func<T, TKey> keySelector, Func<T, TValue> elementSelector)

1. Overload

public static ValueTask<Dictionary<TKey, T>> ToDictionaryAsync<T, TKey>(this IObservableAsync<T> @this, Func<T, TKey> keySelector, IEqualityComparer<TKey>? comparer, CancellationToken cancellationToken) where T : notnull where TKey : notnull

View source

Type parameters

NameDescription
T--
TKey--

Parameters

NameTypeDescription
this[IObservableAsync](#--
keySelectorFunc--
comparerIEqualityComparer?--
cancellationTokenCancellationToken--

Returns: ValueTask>

2. Overload

public static ValueTask<Dictionary<TKey, T>> ToDictionaryAsync<T, TKey>(this IObservableAsync<T> @this, Func<T, TKey> keySelector) where T : notnull where TKey : notnull

View source

Type parameters

NameDescription
T--
TKey--

Parameters

NameTypeDescription
this[IObservableAsync](#--
keySelectorFunc--

Returns: ValueTask>

3. Overload

public static ValueTask<Dictionary<TKey, TValue>> ToDictionaryAsync<T, TKey, TValue>(this IObservableAsync<T> @this, Func<T, TKey> keySelector, Func<T, TValue> elementSelector, IEqualityComparer<TKey>? comparer, CancellationToken cancellationToken)

View source

Type parameters

NameDescription
T--
TKey--
TValue--

Parameters

NameTypeDescription
this[IObservableAsync](#--
keySelectorFunc--
elementSelectorFunc--
comparerIEqualityComparer?--
cancellationTokenCancellationToken--

Returns: ValueTask>

4. Overload

public static ValueTask<Dictionary<TKey, TValue>> ToDictionaryAsync<T, TKey, TValue>(this IObservableAsync<T> @this, Func<T, TKey> keySelector, Func<T, TValue> elementSelector)

View source

Type parameters

NameDescription
T--
TKey--
TValue--

Parameters

NameTypeDescription
this[IObservableAsync](#--
keySelectorFunc--
elementSelectorFunc--

Returns: ValueTask>