Example #1
0
        public ImmutableMap <TKey, TValue> SetItems([NotNull] IEnumerable <KeyValuePair <TKey, TValue> > items)
        {
            if (items is null)
            {
                throw new ArgumentNullException(nameof(items));
            }

            items = items.Materialize();

            return(new ImmutableMap <TKey, TValue>(Base.SetItems(items), Reversed.SetItems(items.ReversePairs())));
        }