document.Yowl.register( "geo", [ "Found a Location" ], [ 0 ], "http://argot-hub.googlecode.com/svn/trunk/_images/geotag_32.png" );
select: [ "s", "location", "apikey" ], where: [ { pattern: [ "?s", "http://purl.org/dc/terms/coverage", "?location" ] }, { pattern: [ "?doc", "http://argot-hub.googlecode.com/googleapikey", "?apikey" ] } ]
document.Yowl.notify( "Found a Location", "Found location: " + ${location.content}, "Geocoding...", "geo", null, false, 0 );
url: 'http://maps.google.com/maps/geo', params: { q: ${location.content}, callbackParamName: 'callback', key: ${apikey.content}, output: 'json' }
if (data.Status && data.Status.code === 200) { document.meta.store.add( ${s}, "a", "http://www.w3.org/2003/01/geo/wgs84_pos#SpatialThing", false ); document.meta.store.add( ${s}, "http://www.w3.org/2003/01/geo/wgs84_pos#lat", { content: data.Placemark[0].Point.coordinates[0], datatype: "" }, true ); document.meta.store.add( ${s}, "http://www.w3.org/2003/01/geo/wgs84_pos#long", { content: data.Placemark[0].Point.coordinates[1], datatype: "" }, true ); }
select: [ "s", "location" ], where: [ { pattern: [ "?s", "http://purl.org/dc/terms/coverage", "?location" ], setUserData: true }, { pattern: [ "?s", "a", "http://www.w3.org/2003/01/geo/wgs84_pos#SpatialThing" ] } ]
Geocoded: ${location.content}