Support paginate(:total_entries => n) for DataMapper

Useful in combination with Postgres and a data set that is bigger than the available memory, since Postgres cannot always answer a select count(*) by looking at the index. Instead it has to go through every row in the result set to check it's visibility information.