Writes a map to a file.
path to where the map should be dumped to
function called for each key/value to confirm that it should be dumped
See Implementation
Writes a map to a file.