- From: Jamie Lokier <jamie@shareable.org>
- Date: Wed, 3 Sep 2008 00:22:56 +0100
- To: Kris Zyp <kris@sitepen.com>
- Cc: Henrik Nordstrom <henrik@henriknordstrom.net>, ietf-http-wg <ietf-http-wg@w3.org>
Kris Zyp wrote: > > >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... What about Range: items=2-4 Range: items=2-5 Is the JSON parser expected to look at the text it receives to decide whether to append "]"? If so, why bother sending the "[" and "]" at all? -- Jamie
Received on Tuesday, 2 September 2008 23:23:35 UTC