Table of Contents

ToEnumerable Method

Definition

ToEnumerable<TKey, TValue>(IDecorator<IDictionary<TKey, TValue>>)

Returns the enclosed IDictionary<TKey, TValue> of the decorator typed as KeyValuePair<TKey, TValue> sequence.

public static IEnumerable<KeyValuePair<TKey, TValue>> ToEnumerable<TKey, TValue>(this IDecorator<IDictionary<TKey, TValue>> decorator)

Parameters

decorator IDecorator<IDictionary<TKey, TValue>>

The IDecorator<T> to extend.

Returns

IEnumerable<KeyValuePair<TKey, TValue>>

A KeyValuePair<TKey, TValue> equivalent sequence of the enclosed IDictionary<TKey, TValue> of the decorator.

Type Parameters

TKey

The type of the keys in the dictionary.

TValue

The type of the values in the dictionary.

Exceptions

ArgumentNullException

decorator cannot be null.