NOTATION Attribute Type | |
... NOTATION (notation [| notation]*) ... The NOTATION attribute mechanism lets XML document authors indicate that the character content of some elements obey the rules of some formal language other than XML. The following short sample document shows how notations might be used to specify the type of programming language stored in the code_fragment element: <?xml version="1.0"?> <!DOCTYPE code_fragment [ <!NOTATION java_code PUBLIC "Java source code"> <!NOTATION c_code PUBLIC "C source code"> <!NOTATION perl_code PUBLIC "Perl source code"> <!ELEMENT code_fragment (#PCDATA)> <!ATTLIST code_fragment code_lang NOTATION (java_code | c_code | perl_code) #REQUIRED> ]> <code_fragment code_lang="c_code"> main( ) { printf("Hello, world."); } </code_fragment> |