moved Paginate class to Paginate/Pager class.
extracted html related code from Pager to ToHtml class.