Re: issue 85 - range unit extensions

> tis 2008-09-02 klockan 08:37 -0600 skrev Kris Zyp:
>
>> I didn't know there was such rules for alternate range units.
>
> There isn't any struct rules for range units, but this property is
> highly desireable for different implementations to interoperate properly
> when it comes to merging and splitting.

After thinking about this, I actually have no problem with this rule being 
enforced, I think that is a good suggestion. I had been thinking it would be 
more desirable that the individual "ranged" response representations all be 
valid complete JSON messages themselves, but I don't think that is 
necessary. I am perfectly fine with have ranges all being concatenable 
without any JSON parsing.

GET /jsonResource
Range: items=0-1

response:
["a","b",

GET /jsonResource
Range: items=2-

response:
"c","d"]

GET /jsonResource

response:
["a","b","c","d"]

A puts little extra overhead on the client doing JSON parsing to properly 
pre/postpend the string to parse it, but this is a negligible cost...

Thanks,
Kris 

Received on Tuesday, 2 September 2008 19:50:56 UTC