For every match, add the element to the Map with the corresponding port. (Kind of a caching technique)