added some map utility functions