pub fn demux_map<Key, Si, Item>(
sinks: impl Into<HashMap<Key, Si>>,
) -> DemuxMap<Key, Si>
Available on crate feature
std
only.Expand description
Creates a DemuxMap
sink that sends each item to one of many outputs, depending on the key.
This requires sinks Si
to be Unpin
. If your sinks are not Unpin
, first wrap them in Box::pin
to make them Unpin
.