From: Mike Taylor Date: Mon, 6 Nov 2006 17:24:00 +0000 (+0000) Subject: Calculate supported booleans. X-Git-Tag: CPAN-v1.02~830 X-Git-Url: http://jsfdemo.indexdata.com/cgi-bin?a=commitdiff_plain;h=5862d2e2bfecfe20419dba258d20592cbcd6b07a;p=irspy-moved-to-github.git Calculate supported booleans. --- diff --git a/web/htdocs/details/full.mc b/web/htdocs/details/full.mc index cb2df50..bc8a739 100644 --- a/web/htdocs/details/full.mc +++ b/web/htdocs/details/full.mc @@ -1,4 +1,4 @@ -%# $Id: full.mc,v 1.9 2006-11-06 17:04:23 mike Exp $ +%# $Id: full.mc,v 1.10 2006-11-06 17:24:00 mike Exp $ <%args> $id @@ -47,7 +47,7 @@ if ($n == 0) { [ "Services" => sub { "### IRSpy does not yet check for search, present, delSet, concurrentOperations, namedResultSets, etc. and store the information is a usable form." } ], [ "Bib-1 Use attributes" => \&calc_ap, $xc, "bib-1" ], [ "Dan-1 Use attributes" => \&calc_ap, $xc, "dan-1" ], - [ "Operators" => sub { "### and, or, not" } ], + [ "Operators" => \&calc_boolean, $xc ], [ "Record syntaxes" => sub { "### SUTRS, USmarc, Danmarc" } ], [ "Explain" => sub { "### CategoryList, TargetInfo, DatabaseInfo, RecordSyntaxInfo, AttributeSetInfo, AttributeDetails" } ], ); @@ -124,4 +124,14 @@ sub calc_ap { return "$nbib1 access points: $res"; } +sub calc_boolean { + my($xc) = @_; + + ### Note that we are currently interrogating an IRSpy extension. + # The standard ZeeRex record should be extended with a + # "supports" type for this. + my @nodes = $xc->findnodes('i:status/i:boolean[@ok = "1"]'); + return join(", ", map { $_->findvalue('@operator') } @nodes); +} +