There is even a better way to create a Map along with initialization:
Map<String, String> rightHereMap = new HashMap<String, String>()
{
{
put("key1", "value1");
put("key2", "value2");
}
};
For more options take a look here How can I initialise a static Map?