Stax 是否有标准 API,以便我可以更换库来查看最快的库?
stax 是否有一个标准 api,以便我可以以某种通用方式编写代码来读取 xml 文件并将它们加载到我的 java 对象中,如果我愿意,我可以交换 xml stax 解析器的实现吗?
常见的 stax 解析器有哪些?
Does stax have a standard api such that I can somehow write my code in a generic way to read an xml file and load them into my java objects, and if I want I can swap out implementations of the xml stax parser?
What are the common stax parsers out there?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

是的,
javax.xml.stream
类是 java 中的标准 StAX api。 sun/oracle jdk 附带了一个较旧的、稍微修改过的 woodstox StAX 实现版本。出于我们的目的,我们添加了 woodstox 实现的较新版本,并且在功能和性能方面对其非常满意。不过,我还没有对其他实现进行太多研究。yes, the
javax.xml.stream
classes are the standard StAX api in java. the sun/oracle jdk comes with an older, slightly modified version of the woodstox StAX implementation. for our purposes, we've included a newer version of the woodstox implementation and been very happy with it in terms of features and performance. i have not done much research into other implementations, though.