Add keys() and values() methods for SmallIntMap, TreeMap and TrieMap

Adds methods for obtaining iterators over the keys or values of a SmallIntMap/TreeMap/TrieMap.

Closes #14376