URI Templates

1 view
Skip to first unread message

Eran Hammer-Lahav

unread,
Jul 22, 2008, 12:28:51 AM7/22/08
to Email-Address-To-URL Transform (EAUT)
You might want to use the upcoming XRDS-Simple templates coming in
draft 2. You can just reference it directly before that draft is out.

Basically it will include a new element <simple:TemplateURI> which
will directly reference http://tools.ietf.org/html/draft-gregorio-uritemplate-03.
So it will look something like:

<Service>
<Type>http://eaut.org/spec/1.0</Type>
<TemplateURI>http://example.com/{username}</TemplateURI>
</Service>

or

<Service>
<Type>http://eaut.org/spec/1.0</Type>
<URI>http://example.com/mapper</URI>
</Service>

And you only need one Type because you use two separate elements for
real URI and templates. Also saves you defining the template mechanism
by using the IETF draft.

EHL

David Fuelling

unread,
Jul 22, 2008, 12:45:17 AM7/22/08
to ea...@googlegroups.com
On Tue, Jul 22, 2008 at 4:28 AM, Eran Hammer-Lahav <er...@hueniverse.com> wrote:

You might want to use the upcoming XRDS-Simple templates coming in
draft 2. You can just reference it directly before that draft is out.

Basically it will include a new element <simple:TemplateURI> which
will directly reference http://tools.ietf.org/html/draft-gregorio-uritemplate-03.
So it will look something like:

<Service>
   <Type>http://eaut.org/spec/1.0</Type>
   <TemplateURI>http://example.com/{username}</TemplateURI>
</Service>

or

<Service>
   <Type>http://eaut.org/spec/1.0</Type>
   <URI>http://example.com/mapper</URI>
</Service>

And you only need one Type because you use two separate elements for
real URI and templates.

That's really cool.  Will it be valid to specify two URL-like elements (one URL and one Template) within a single "Service" element.  For example:

<Service>
   <Type>http://eaut.org/spec/1.0</Type>
   <URI priority="1">http://example.com/mapper</URI> 
   <TemplateURI priority="10">http://example.com/{username}</TemplateURI>
</Service>

I guess what I'm getting at is:  Are the "URI" element and the "TemplateURI" element considered to be a part of the same Service type?
 
Also saves you defining the template mechanism
by using the IETF draft.

Does that mean you're going to specify your own templating mechanism, based upon the gregario-draft (but fully defined in XRDS-Simple), or will you just have a pointer to the URI template spec in the same way EAUT currently does?

Eran Hammer-Lahav

unread,
Jul 22, 2008, 1:56:22 AM7/22/08
to ea...@googlegroups.com
The plan is to just reference the ietf spec and to note it is a draft. You can put both elements under the same service as long as you type defines how they should be used.
Reply all
Reply to author
Forward
0 new messages