Extracting shared strings functionality into a separate class.