RE: Input to BP1 http://www.w3.org/International/its/techniques/its-techniques.html#Dev Lang

Hi Yves, all again,

>
> Hi Yves,
>
>> Hi Felix,
>>
>> I would agree with a warning note.
>>
>>> "Note: Make sure that the definition of the xml:lang attribute
>>> allows for empty values. That is, you must not use e.g. NMTOKEN
>>> as the data type. The XML Schema built in data type 'language'
>>> does not allow for empty values. Hence it must be used with care
>>> or avoid.
>>
>>
>> A) should be "avoided" rather than "avoid".
>
> thanks, sure.
>
>>
>> B) The statements: "Make sure...allows for empty values" and
>> "...'language' does not allow for empty values. Hence it must be used
>> with care or avoided" seem a bit contradictory: 'language' cannot be
>> used
>> if you need to 'make sure'.
>
> agree. How about:
> " ... You must not use the NMTOKEN data type. Note that the XML Schema
> built in data type 'language' does not allow for empty values and hence
> must be used with care or avoided"
>
>>
>> C) We say what not to use, but do not provide an example of what to use.
>> If we cannot use NMTOKEN nor 'language' what should the
>> developer use?
>
> in DTDs CDATA. I'll check for XML Schema and come back to this issue.

We should point people to the XML Schema document for the XML namespace, see
http://www.w3.org/2001/xml.xsd . It defines for xml:lang a union type of
the language data type and an empty value:

 <xs:simpleType>
   <xs:union memberTypes="xs:language">
    <xs:simpleType>
     <xs:restriction base="xs:string">
      <xs:enumeration value=""/>
     </xs:restriction>
    </xs:simpleType>
   </xs:union>
  </xs:simpleType>

I would recommend that people use that definition for XML Schema or RELAX NG.

Felix

>
> Cheers,
>
> Felix
>
>>
>>
>> Cheers,
>> -ys
>>
>>
>>
>
>
>
>

Received on Tuesday, 5 June 2007 00:30:03 UTC