/// <summary> /// Creates an <see cref="IDictionary{TKey, TValue}" /> from an <see cref="IFields" /> /// </summary> /// <param name="source">An <see cref="IFields" /> to create an <see cref="IDictionary{TKey, TValue}" /> from.</param> /// <returns> /// An <see cref="IDictionary{TKey, TValue}" /> that contains the fields from the input source. /// </returns> public static IDictionary <string, int> ToDictionary(this IFields source) { return(source.ToDictionary(field => field != null)); }