|
|
|
|
@ -57,7 +57,7 @@ inline fun <reified T : Filterable> List<QueryCondition>.query(realm: Realm): Re |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
fun <T> getCombinations(lists: List<List<T>>): List<List<T>> { |
|
|
|
|
var combinations: MutableSet<List<T>> = HashSet() |
|
|
|
|
var combinations: MutableSet<List<T>> = LinkedHashSet() |
|
|
|
|
var newCombinations: MutableSet<List<T>> |
|
|
|
|
|
|
|
|
|
var index = 0 |
|
|
|
|
@ -72,7 +72,7 @@ fun <T> getCombinations(lists: List<List<T>>): List<List<T>> { |
|
|
|
|
index++ |
|
|
|
|
while (index < lists.size) { |
|
|
|
|
val nextList = lists[index] |
|
|
|
|
newCombinations = HashSet() |
|
|
|
|
newCombinations = LinkedHashSet() |
|
|
|
|
for (first in combinations) { |
|
|
|
|
for (second in nextList) { |
|
|
|
|
val newList = ArrayList<T>() |
|
|
|
|
|