Last week I sent out an email about some feedback I got on the 
geo-web-rest mailing list. So I set out to implement a "discovery 
document" as specified here:

http://xrds-simple.net/core/1.0/

My first thought was to more or less do what the IndexRestlet does, 
generate the document from registered routes, however I am finding it a 
bit lacking for what I need. While I could apply the same heuristic of 
only including routes that do not contain any variables, I think it 
might be useful to have something a bit more explicit. Especially if we 
adopt the URI template stuff that the opensocial stuff uses:

http://bitworking.org/news/URI_Templates

Also with the above approach there is no great way to figure out what 
the accepted media types of formats are.

So my thought is to instead add a sort of marker interface called 
"Discoverable". It would look something like this:

interface Discoverable {

   String getType();

   String getURI();

   List<MediaType> getMediaTypes();

}

The uri property may be unnecessary as it could be derived from the 
route mapping. But the idea is that restlets that are "discoverable" 
would implement this interface.

Thoughts?

-- 
Justin Deoliveira
OpenGeo - http://opengeo.org
Enterprise support for open source geospatial.

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Geoserver-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

Reply via email to