From 52d4aac8b44ac72ee7274ace6eb6cd09434c4293 Mon Sep 17 00:00:00 2001 From: Marc Cromme Date: Fri, 6 Oct 2006 22:30:01 +0000 Subject: [PATCH] added specific validating instructions for the filter types ( filter_refid | filter_auth_simple | filter_backend_test | filter_bounce | filter_frontend_net | filter_http_file | filter_log | filter_multi | filter_query_rewrite | filter_virt_db | filter_z3950_client ) --- xml/schema/metaproxy.rnc | 108 +++++++++++++++++++++++++++++++++------------- 1 file changed, 78 insertions(+), 30 deletions(-) diff --git a/xml/schema/metaproxy.rnc b/xml/schema/metaproxy.rnc index f648a18..9ea24b6 100644 --- a/xml/schema/metaproxy.rnc +++ b/xml/schema/metaproxy.rnc @@ -1,6 +1,6 @@ # The RelaxNG Compact Syntax file is the master copy # trang metaproxy.rnc metaproxy.rng -# xmllint --relaxng metaproxy.rng ../../../etc/config1.xml +# xmllint -/-relaxng metaproxy.rng ../../../etc/config1.xml # see also http://books.xmlschemata.org/relaxng/relax-CHP-16-SECT-2.html default namespace = "http://indexdata.dk/yp2/config/1" @@ -20,52 +20,100 @@ metaproxy = route = element route { attribute id { xsd:NCName }, - (filter - | filter_ref_id - )+ + filter+ } filter = - (filter_log - | filter_bounce - | filter_frontend_net - | filter_z3950_client - ) - -filter_ref_id = element filter { - attribute refid { xsd:NCName } - } + ( filter_refid + | filter_auth_simple + | filter_backend_test + | filter_bounce + | filter_frontend_net + | filter_http_file + | filter_log + | filter_multi + | filter_query_rewrite + | filter_virt_db + | filter_z3950_client + ) +} -filter_bounce = - element filter { +filter_refid = attribute refid { xsd:NCName } + +filter_auth_simple = + attribute type { "auth_simple" }, + attribute id { xsd:NCName }?, + attribute name { xsd:NCName }?, + element userRegister { xsd:string }?, + element targetRegister { xsd:string }?, + element discardUnauthorisedTargets { empty }? + +filter_backend_test = + attribute type { "backend_test" }, + attribute id { xsd:NCName }?, + attribute name { xsd:NCName }? + +filter_bounce = attribute type { "bounce" }, attribute id { xsd:NCName }?, - attribute name { xsd:NCName } - } + attribute name { xsd:NCName }? -filter_log = - element filter { +filter_frontend_net = + attribute type { "frontend_net" }, + attribute id { xsd:NCName }?, + attribute name { xsd:NCName }?, + element threads { xsd:integer }?, + element port { xsd:string } + +filter_http_file = + attribute type { "http_file" }, + attribute id { xsd:NCName }?, + attribute name { xsd:NCName }?, + element mimetypes { xsd:string }, + element area { + element documentroot { xsd:string }, + element prefix { xsd:string } + } + +filter_log = attribute type { "log" }, attribute id { xsd:NCName }?, attribute name { xsd:NCName }?, - element message { xsd:NCName }? - } + element message { xsd:NCName }, + element filename { xsd:string }?, + element category { + attribute request-session { xsd:boolean }?, + attribute response-session { xsd:boolean }?, + attribute request-apdu { xsd:boolean }?, + attribute response-apdu { xsd:boolean }? + }? -filter_frontend_net = - element filter { - attribute type { "frontend_net" }, +filter_multi = + attribute type { "multi" }, attribute id { xsd:NCName }?, attribute name { xsd:NCName }?, - element threads { xsd:integer }, - element port { xsd:string } - } + element hideunavailable { empty }? -filter_z3950_client = - element filter { +filter_query_rewrite = + attribute type { "query_rewrite" }, + attribute id { xsd:NCName }?, + attribute name { xsd:NCName }?, + element xslt { xsd:string } + +filter_virt_db = + attribute type { "virt_db" }, + attribute id { xsd:NCName }?, + attribute name { xsd:NCName }?, + element virtual { + attribute route { xsd:NCName }?, + element database { xsd:NCName }, + element target { xsd:string }+ + }+ + +filter_z3950_client = attribute type { "z3950_client" }, attribute id { xsd:NCName }?, attribute name { xsd:NCName }?, element timeout { xsd:integer } - } -- 1.7.10.4