Add util functions to deal with map operations