| 30 | |
| 31 | To achieve this we have to make the following changes to the XSD generated by the CR: |
| 32 | |
| 33 | {{{#!xml |
| 34 | <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:dcr="http://www.isocat.org/ns/dcr" xmlns:cmd="http://www.clarin.eu/cmd/" targetNamespace="http://www.clarin.eu/cmd/" elementFormDefault="qualified"> |
| 35 | ... |
| 36 | <!-- globally declare @ref and @ComponentId, so they have to be qualified --> |
| 37 | <xs:attribute name="ref"/> |
| 38 | <xs:attribute name="ComponentId" type="xs:anyURI"/> |
| 39 | ... |
| 40 | <xs:element name="myComponent" ... > |
| 41 | <xs:complexType> |
| 42 | <xs:sequence> |
| 43 | ... |
| 44 | </xs:sequence> |
| 45 | <!-- refer to the globally declared attributes --> |
| 46 | <xs:attribute ref="cmd:ref"/> |
| 47 | <xs:attribute ref="cmd:ComponentId" fixed="clarin.eu:cr1:c_1328259700912"/> |
| 48 | </xs:complexType> |
| 49 | </xs:element> |
| 50 | ... |
| 51 | </xs:schema> |
| 52 | }}} |
| 53 | |
| 54 | Note: cleanup-xsd.xsl also needs to be adopted as it currently will prune away the new global <xs:attribute/> elements. |