IMapOfSets<K, V>.from constructor

IMapOfSets<K, V>.from(
  1. IMap<K, ISet<V>> imap, {
  2. ConfigMapOfSets? config,
})

Creates an IMapOfSets from an IMap of sets. The resulting map and its sets will be sorted according to config, or, if not provided, according to the default configuration for ConfigMapOfSets.

Implementation

IMapOfSets.from(IMap<K, ISet<V>> imap, {ConfigMapOfSets? config})
    : config = config ?? IMapOfSets.defaultConfig,
      _mapOfSets = _setsWithConfig(imap, config ?? IMapOfSets.defaultConfig);