Feedback for Limit / Offset Based Pagination

Hi,

based on the new hydra:PartialCollectionView based pagination
I have tried to combine this with the limit / offset based pagination
scheme (that I want to keep) and here is the result based on a JSON-LD 
example:

"@id": "http://example.com/events/",
"@type": "Collection",
"totalItems": 12664,
"member": [
   ...
],
"view": {
   "@id": "http://example.com/events/?limit=250&offset=250",
   "@type": [ "hydra:PartialCollectionView", "ex:PartialCollectionView" ],
   "first": "/events/?limit=250",
   "previous": "/events/?limit=250&offset=0",
   "next": "/events/?limit=250&offset=500",
   "last": "/events/?limit=250&offset=12500",
   "ex:offset": 250,
   "ex:membersPerView:" {
     "@type": "IriTemplate",
     "ex:defaultLimit": "100",
     "template": "/events/{?limit,offset}",
     "mapping": [
       {
         "@type": "IriTemplateMapping",
         "variable": "limit",
         "property": "ex:PartialCollectionView#limit"
       },
       {
         "@type": "IriTemplateMapping",
         "variable": "offset",
         "property": "ex:PartialCollectionView#offset"
       }
     ]
   }
}

Everything is from hydra: except for the stuff I've prefixed with ex:

So obviously I have introduced a new class with the properties ex:limit 
and ex:offset which
should carry the actual semantics of this pagination scheme.
I had a quick look at other vocabs and could find something matching in 
SPIN:

http://spinrdf.org/sp#limit


BG, Thomas

Received on Monday, 21 December 2015 07:58:15 UTC