W3C home > Mailing lists > Public > xmlschema-dev@w3.org > April 2003

different attribute value sets for the same element ref?

From: Giles Hogben <giles.hogben@jrc.it>
Date: Mon, 14 Apr 2003 12:14:00 +0200
To: <xmlschema-dev@w3.org>
Message-ID: <GAEKIJGJBJOBBJEFAHMLEEMDCIAA.giles.hogben@jrc.it>
Hi,
I'm looking for help on the following problem:

1. I have a "category" element which I want to use in my language in
different places with different sets of restricted values of attributes (all
taken from a predefined list of 14).

For example the following would be allowed

<data-type>
    <home>
        <category name="X || Y || Z">
    </home>
</data-type>

Or

<data-type>
    <business>
        <category name="W || X || Z">
    </business>
</data-type>

I thought about doing it something like this:


<xs:element name="home">
    <xs:element ref="category">
        <xs:attribute ref="name">
            <xs:choice>
                ??????
            </xs:choice>
        </xs:attribute>
    </xs:element>
</xs:element>

but I can't figure out how it should go.

Can anyone tell me the right way to do this?

Thanks

Giles Hogben
Received on Monday, 14 April 2003 06:11:38 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:36 GMT