// get all secondary dictionaries
for (TreeMap<TKey2, List<TResult>> tree : dict.values())
for (List<TResult> list : tree.values())
result.addAll(list);
return result.toArray();
}
/**
* Partitions the given values based on a predicate. Matching values are first, non-matching second.
*