Creates a snapshot of all keys in a hash map. If the map is changed afterwards, the changes are not reflected in the snapshot. Keys are not sorted.
New map snapshot handle, which must be freed via TrieSnapshotDestroy()
If an invalid handle is provided an error will be thrown.