Either the built-in entity or a character reference can be used to represent greater-than after two close-square-brackets
<!DOCTYPE foo [ <!ELEMENT foo ANY> <!ENTITY gt ">"> ]> <foo>You can use ]]> or ]]></foo>
Expected result | Actual result for com.jclark.xml.sax.SAX2Driver |
---|---|
<?xml version="1.0" encoding="UTF-8"?> <ConformanceResults> <startDocument/> <startElement> <namespaceURI/> <localName>foo</localName> <qualifiedName>foo</qualifiedName> <attributes/> </startElement> <char>Y</char> <char>o</char> <char>u</char> <char>\s</char> <char>c</char> <char>a</char> <char>n</char> <char>\s</char> <char>u</char> <char>s</char> <char>e</char> <char>\s</char> <char>]</char> <char>]</char> <char>></char> <char>\s</char> <char>o</char> <char>r</char> <char>\s</char> <char>]</char> <char>]</char> <char>></char> <endElement> <namespaceURI/> <localName>foo</localName> <qualifiedName>foo</qualifiedName> </endElement> <endDocument/> </ConformanceResults> | <?xml version="1.0" encoding="UTF-8"?> <ConformanceResults> <startDocument/> <startElement> <namespaceURI/> <localName>foo</localName> <qualifiedName>foo</qualifiedName> <attributes/> </startElement> <char>Y</char> <char>o</char> <char>u</char> <char>\s</char> <char>c</char> <char>a</char> <char>n</char> <char>\s</char> <char>u</char> <char>s</char> <char>e</char> <char>\s</char> <char>]</char> <char>]</char> <char>></char> <char>\s</char> <char>o</char> <char>r</char> <char>\s</char> <char>]</char> <char>]</char> <char>></char> <endElement> <namespaceURI/> <localName>foo</localName> <qualifiedName>foo</qualifiedName> </endElement> <endDocument/> </ConformanceResults> |