[relaxng-user] specifying attribute choice

DuCharme, Bob (LNG-CHO) bob.ducharme at lexisnexis.com
Mon Feb 9 12:00:41 ICT 2004


I'm trying to figure out how I can specify that an element must have at
least one of a certain set of attributes and may have the others as well. If
the attributes are called x, y, and z, I could say something like ((x & y?
&z?) | (x? & y & z?)| (x? & y? & z)), but it doesn't scale up well.
Something like

  attlist.a =
    (attribute x {text},
     attribute y {text},
     attribute z {text})+

gives me an error because it allows for more than one of any individual
attribute. Any suggestions?

thanks,

Bob



More information about the relaxng-user mailing list