W3C home > Mailing lists > Public > uri@w3.org > August 2007

Re: URI Templates - optional variables?

From: Marc Hadley <Marc.Hadley@Sun.COM>
Date: Wed, 01 Aug 2007 17:33:36 -0400
To: Mike Schinkel <mikeschinkel@gmail.com>
Cc: uri@w3.org
Message-id: <5C1FF16C-01BE-4ACC-BEAD-82F59A10B66C@Sun.COM>

On Aug 1, 2007, at 3:55 PM, Mike Schinkel wrote:
>
> Where it would be most useful in path segments is when you view the  
> URL path
> segments as a generalized query mechanism:
>
>     http://example.com/{make?}/{model?}/{year?}/
>
> For make=bmw, model=, and year=2004 you would have:
>
>     http://example.com/bmw/2004/
>
> For make=, model=m5, and year= you would have:
>
>     http://example.com/m5/
>
Just a thought but the current draft would give you (ignoring the '?'  
in your template):

http://example.com/bmw//2004/ and
http://example.com//m5//

Which are both nicely unambiguous...

Marc.


---
Marc Hadley <marc.hadley at sun.com>
CTO Office, Sun Microsystems.
Received on Wednesday, 1 August 2007 21:33:29 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:25:11 UTC