X-Git-Url: http://lists.indexdata.dk/cgi-bin?a=blobdiff_plain;f=samples%2Fzoom%2Fzoomtst3.pl;h=eb72ed0bc45bdac9f743f66f114912af98d59370;hb=a032022a32bbc0d1ed46990ca8e79889ce41cb1f;hp=8d4a23238abc6c900ad397076f749b23f8d34bd8;hpb=e33d1ad7c6035f87a3893b5591b18b8a26475ae4;p=ZOOM-Perl-moved-to-github.git diff --git a/samples/zoom/zoomtst3.pl b/samples/zoom/zoomtst3.pl index 8d4a232..eb72ed0 100644 --- a/samples/zoom/zoomtst3.pl +++ b/samples/zoom/zoomtst3.pl @@ -1,7 +1,9 @@ -# $Id: zoomtst3.pl,v 1.1 2006-04-07 11:07:12 mike Exp $ +# $Id: zoomtst3.pl,v 1.6 2006-11-02 17:48:26 mike Exp $ # # See ../README for a description of this program. # perl -I../../blib/lib -I../../blib/arch zoomtst3.pl [...] +# for example: +# perl -I../../blib/lib -I../../blib/arch zoomtst3.pl z3950.loc.gov:7090/Voyager z3950.indexdata.com:210/gils endeavor.flo.org:7090/Voyager mineral use strict; use warnings; @@ -9,7 +11,7 @@ use ZOOM; if (@ARGV < 2) { print STDERR "Usage: $0 target1 target2 ... targetN query\n"; - print STDERR " eg. $0 bagel.indexdata.dk/gils localhost:9999 fish\n"; + print STDERR " eg. $0 z3950.indexdata.dk/gils localhost:9999 fish\n"; exit 1; } @@ -28,7 +30,7 @@ $o->option(elementSetName => "F"); # Connect to all targets: options are the same for all of them for (my $i = 0; $i < $n; $i++) { $z[$i] = create ZOOM::Connection($o); - $z[$i]->connect($ARGV[$i], 0); ### remove the "0"? + $z[$i]->connect($ARGV[$i]); } # Search all @@ -40,7 +42,11 @@ for (my $i = 0; $i < $n; $i++) { while ((my $i = ZOOM::event(\@z)) != 0) { my $ev = $z[$i-1]->last_event(); print("connection ", $i-1, ": event $ev (", ZOOM::event_str($ev), ")\n"); - ### It would be nice to display results as they come in. + # It would be nice to display results as they come in, but the + # ability to do so is dependent on the END event, which was + # introduced only in YAZ 2.1.17. If you have a sufficiently new + # YAZ, please use the alternative "async.pl", which is similar to + # this program except in its asynchronous display. } # No more to be done. Inspect results