public static < T , K , U > Collector < T , ? , LinkedHashMap < K , U > > toLinkedMap ( Function < ? super T , ? extends K > keyMapper , Function < ? super T , ? extends U > valueMapper , BinaryOperator < U > mergeFunction ) { return Collectors . toMap ( keyMapper , valueMapper , mergeFunction , LinkedHashMap :: new ) ; }
Collects a stream to a LinkedHashMap .