This work is licensed under a CC |
XSDL allows greater flexibility in defining constraints on intra-document references than the ID/IDREF construct of DTDs. XSDL's Identity Constraints are scoped, typed, and can be used for elements or attributes. They are more powerful that the DTD's limited ID/IDREF mechanism, but still lack sufficient generality to support a really wide set of model constraints to be expressed.
typesare always anonymous (they cannot be reused)
<!ELEMENT person (name, address) >
<!ATTLIST person id ID #REQUIRED >
<xs:complexType name="mixedType" mixed="true"> <xs:choice maxOccurs="unbounded" minOccurs="0"> <xs:element ref="b"/> <xs:element name="i" type="xs:string"/> <xs:element name="u" type="xs:string"/> </xs:choice> <xs:attribute ref="class"/> </xs:complexType> <xs:element name="b" type="xs:string"/>
ATTLIST
, not in the ELEMENT
definition<!ELEMENT person (name, address) >
<!ATTLIST person id ID #REQUIRED >
<!ATTLIST person id ID #REQUIRED >
ATTLIST
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.example.com/">
<html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Multicolumn Layout in HTML</title> <style type="text/css">
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.example.com/" elementFormDefault="qualified" attributeFormDefault="unqualified">
ID
s must be XML names (no numbers allowed)2
≟ +00002
should be evaluated based on the type (string or decimal?)