当前位置: 首页 > 工具软件 > JTidy > 使用案例 >

JTidy的局限

麻鹏鹍
2023-12-01

最近刚学Java,帮人在写HTML->XML->XML变幻数据的东东,曾经知道lucene采用了JTidy,所以拿来就做了parseDOM,谁知道,这里边还有好多限制,把网上看到的冬冬拿出来分享。

http://www.w3.org/People/Raggett/tidy/ 这里写了一些关于HTML Tidy的情况,其中有一点大家要注意

Limited support for XML

XML processors compliant with W3C's XML 1.0 recommendation are very picky about which files they will accept. Tidy can help you to fix errors that cause your XML files to be rejected. Tidy doesn't yet recognize all XML features though, e.g. it doesn't understand CDATA sections or DTD subsets.

看到了,不能很好的识别CDATA的东西,给他家提个醒啦。现在只好换个开发包来用用了:)

 

 类似资料: