How can I create XML from Perl?

后端 未结 6 819
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-05 04:52

I need to create XML in Perl. From what I read, XML::LibXML is great for parsing and using XML that comes from somewhere else. Does anyone have any suggestions for an XML

6条回答
  •  时光说笑
    2020-12-05 05:23

    I like XML::TreeBuilder because it fits the way I think. Historically, I've used it more for parsing than emitting.

    A few weeks after this question was posted, I had occasion to generate some XML from Perl. I surveyed the other modules listed here, assuming one of them would work better than XML::TreeBuilder, but TreeBuilder was still the best choice for what I wanted.

    One drawback was there is no way to represent processing instructions and declarations in an XML::TreeBuilder object.

提交回复
热议问题