increase readability; extract methods to utility class