bnf/ebnf for xml schema

≯℡__Kan透↙ 提交于 2019-12-07 22:54:35

问题


I'm looking for a BNF/EBNF of XML Schema. I just found the one for XML (http://www.w3.org/TR/REC-xml or extracted at http://www.jelks.nu/XML/xmlebnf.html).

Well it's a starting point, but I'm curious that I couldn't find a more specific one for XML Schema.


回答1:


I guess because nobody finds that useful, and it would be too complex. If somebody want to define an XML language, such as XML Schema, they would probably use XML primitives like elements or attributes (using XML Schema, Relax NG, DTD, etc.), not characters. One of the reasons XML was invented is to have a meta language for creating other languages.




回答2:


I think the fiirst step would be to start with the xsd for XML Schema and to use Colibri to generate a bnf grammar.

I will check when i m back home. The Colibri's author say:

Il s'agit là d'un premier jet que nous pourrions affiner.

But i definitevly think it got potential.



来源:https://stackoverflow.com/questions/1578100/bnf-ebnf-for-xml-schema

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!