I don't understand REST pagination

Hey.


So, in txYoga, in implemented pagination in terms of query parameters to a collection. If you want to access the range of elements [100, 110), you would say: http://whatever/collection?start=100;stop=110. The feature here is that pages give you the link to the next and previous page. The response (JSON) looks something like {"results": [...], "next": nextURL, "prev": prevURL}. That way, you pretty much just have to follow URLs to walk down the collection as a doubly  linked list of pages. The supposed feature is that I can change how my pages work, and users hopefully won't notice, since they shouldn't be building their own URLs anyway.

Now, at the same time, I'm looking at dojo's JsonRest API. It's suggesting that I use the Range and Content-Range headers for pagination support. It also has a single JSON array as a response (so, [{...}, ...]) instead of my JSON object. I started RFC diving and hey look, they're right, HTTP understands ranges with arbitrary units. So, are my URLs wrong? Are people supposed to conjure Range URLs themselves? Why are these darned ranges inclusive? Another problem is that the specification doesn't really seem to support non-numeric ranges, whereas to txYoga, that's not really a problem as long as the underlying collection understands it.

Isn't REST supposed to be hypertext-driven? Aren't people basically supposed to never construct URLs, and rely on me to provide them to them? Where am I supposed to put those URLs? Yaaargh.


cheers
lvh