How best to use XPath with very large XML files in .NET?

前端 未结 10 2122
自闭症患者
自闭症患者 2020-12-14 10:07

I need to do some processing on fairly large XML files ( large here being potentially upwards of a gigabyte ) in C# including performing some complex xpath queries. The prob

10条回答
  •  悲哀的现实
    2020-12-14 10:22

    Have you been trying XPathDocument? This class is optimized for handling XPath queries efficiently.

    If you cannot handle your input documents efficiently using XPathDocument you might consider preprocessing and/or splitting up your input documents using an XmlReader.

提交回复
热议问题