修复并发流下的middle未收集的bug

This commit is contained in:
tanglitao 2025-02-13 18:41:49 +08:00
parent 11acd3935d
commit 1e71d24f8c

View File

@ -548,7 +548,7 @@ public class CollectorUtil {
} }
/** /**
* 将一个{@code Collection<T>}两个属性分流至两个Collection,并使用Pair收集需要指定Collection类型 * 将一个{@code Collection<T>}两个属性分流至两个Collection,并使用Triple收集需要指定Collection类型
* *
* @param lMapper 左属性收集方法 * @param lMapper 左属性收集方法
* @param mMapper 中属性收集方法 * @param mMapper 中属性收集方法
@ -594,6 +594,7 @@ public class CollectorUtil {
}, },
(listTriple1, listTriple2) -> { (listTriple1, listTriple2) -> {
listTriple1.getLeft().addAll(listTriple2.getLeft()); listTriple1.getLeft().addAll(listTriple2.getLeft());
listTriple1.getMiddle().addAll(listTriple2.getMiddle());
listTriple1.getRight().addAll(listTriple2.getRight()); listTriple1.getRight().addAll(listTriple2.getRight());
return listTriple1; return listTriple1;
}, },