This example will show how to loop over each entry in a map.
EntrySet
In this snippet we will use a for each loop to iterate through each entry returned by the Maps.entrySet then logging the Map.key and the Map.value.
Iterator
In this snippet we use an Iterator to loop over each Map.entrySet. The Map.entrySet will return an entry which will contain the key and value information.