Refactor Paginator Class