[engine] Implemented a toString function for the map.