Re: uri templates: {?var}

On Jul 13, 2011, at 7:17 AM, Manger, James H wrote:

> It is great to see some more progress on URI templates <draft-gregorio-uritemplate-05>. Thanks Roy.
> 
> 1.
> The form-style query expansions {?var} needs to substitute '?' or '&' based on whether or not a '?' already appears in the URI output string being constructed.

I disagree.  I do not want the expression processor to need
to know the state of the surrounding URI reference.  We then
get into a discussion about what happens when {+foo}{?this}
is the template and foo := "hello?".

> The text about the '?' operator in 1.1 "Overview" isn't clear on this point. It says '?' is used for the first variable with a defined value in the expression. This is true for the specific example used in the overview, but not true in general (when a template might have some query parameters as literals).

In that case, the template should not be using the ? operator.
It should be using foo?literal=here&var={variable}

The description does have a problem with defaults, though.

....Roy

Received on Thursday, 14 July 2011 22:19:09 UTC