Extracting methods to collection class

Remove the class method dependency as it becomes harder to refactor.