Adds map metadata reading, and hopefully fixes out PMD warnings.