A number of folks have pointed out that it would be useful to be able
to describe the linkages between described resources in addition to
the HTTP methods that can be applied to those resources and the
representation formats supported. Whilst it would be possible at
runtime to compare a URI with the URIs of all of the resources in a
description to identify a match, I think it would be preferable to be
able to specify the resource targeted by a link up front where that
information is known.
This can be achieved in WADL by adding a new element to the language:
<link>. The <link> element can be used as a child of the existing
<representation_variable> element and is used to indicate that the
value of a representation component is a link to a described
resource. The <link> element is syntactically similar to the HTML
<link> element but differs semantically in that its href attribute
identifies a <resource> element rather than a linked document. The
parent <representation_variable> element identifies that part of the
representation that contains the link. E.g.
The values of the rel and rev attributes are an open set including
those used by convention in HTML. Similar to HTML, a profile
attribute may be added to the application element to define a
namespace for additional link types.
Thoughts, comments ?
Marc Hadley <marc.hadley at sun.com>
Business Alliances, CTO Office, Sun Microsystems.