am_map_for_each() will iterate over the list of key/value pairs and call each one. For every key in the map, a function can be invoked via the function pointer.