[OAI-implementers] Validating ListMetadataFormats

Steven Bird Steven Bird <sb@ldc.upenn.edu>
2002年2月08日 10:24:56 EST


I would like to use an XML validation language (e.g. XML Schema) to test
that the document returned by ListMetadataFormats includes a specific
format. The return typically lists multiple formats, and I just want to
check that the list includes one specific format, e.g.:
<ListMetadataFormats>
 ...
 <metadataFormat>
 <metadataPrefix>olac</metadataPrefix>
 <schema>http://www.language-archives.org/OLAC/0.4/olac.xsd</schema>
 <metadataNamespace>http://www.language-archives.org/OLAC/0.4/</metadataNamespace>
 </metadataFormat>
 ...
</ListMetadataFormats>
The ListMetadataFormats container is supposed to have set semantics. I
guess I need a set-membership test, and it also needs to work on element
content (not just element names, attribute names, or attribute values).
Of course it is trivial to write a program to do the test, but I was hoping
to find a fully declarative solution, so that our formal requirements
[http://www.language-archives.org/OLAC/protocol.html] can be accompanied by
one or more XML documents which more or less transparently implement them.
I would be grateful for any advice about how to test for set membership
using an XML validation language.
Thanks,
Steven Bird
--
Steven.Bird@ldc.upenn.edu http://www.ldc.upenn.edu/sb
Assoc Director, LDC; Adj Assoc Prof, CIS & Linguistics
Linguistic Data Consortium, University of Pennsylvania
3615 Market St, Suite 200, Philadelphia, PA 19104-2608

AltStyle によって変換されたページ (->オリジナル) /