mirror of
https://github.com/tiennm99/zfoo.git
synced 2026-10-13 00:15:24 +00:00
perf[random]: get all elements of RandomSelector
This commit is contained in:
1 parent
bd236a2622
commit
f0ad2dfa02
1 file changed
+4
@@ -16,6 +16,7 @@ package com.zfoo.util.math;
|
||||
import org.springframework.lang.Nullable;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import java.util.TreeMap;
|
||||
|
||||
@@ -67,4 +68,7 @@ public class RandomSelector<T> {
|
||||
return resultList;
|
||||
}
|
||||
|
||||
public Collection<T> getAll() {
|
||||
return elementMap.values();
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user