querying Annotea annotations with Squish and SOAP

(I've changed the address of the SOAP service for now...)

Here's how one can query annotations via SOAP/Squish. Backend is EricP's
Perllib database. I'm not including the query results here due to possible
query concerns. I've done this so I can show interop between ILRT's
MedCERTAIN tools and other annotation systems such as Annotea.

--danbri

---------- Forwarded message ----------
Date: Sat, 01 Sep 2001 00:21:10 -0400
From: Dan Brickley <danbri@w3.org>
To: danbri@w3.org

#!/usr/bin/perl -w

use SOAP::Lite;

my $query =    'SELECT ?x, ?y, ?c, ?b
		WHERE
		  (an::annotates ?x ?y)
		  (an::created ?x ?c)
		  (an::body ?x ?b)
		USING
		  an for http://www.w3.org/2000/10/annotation-ns#
		  dc for http://purl.org/dc/elements/1.1/';

my $soap = SOAP::Lite
 -> uri('http://rdfweb.org/RDF/RDFWeb/SOAPDemo')
 -> proxy('http://example.com/annotationserver/soap');

my $r = $soap->squish($query)->result();

print "Result is $r: \n\n";
my @res = @{$r};

foreach my $row ( @{$r} ) {
  my %h = %{$row } ;
  print "\n\n";
  foreach (keys %h) {
	print " $_ -> ", $h{$_}, " \n";
  }
}

Received on Saturday, 1 September 2001 09:22:55 UTC