I just stumbled across this
new custom XmlReader sample, XmlBookmarkReader,and had one of those "why didn`t I think of that" moments. It basically lets you set bookmarks on nodes that you might want to return to when you`re further down the node stream. It accomplishes this by caching the bookmarked node, and the nodes that follow it up to the current position, so they can all be replayed if necessary, giving you a handy hybrid between the efficiencies of a forward only cursor and the flexibility of temporary caching. Kudos to
Helena. She is one of the women Dare wrote about in his post on
Women in XML. According to him she`s been responsible for a lot of the work on the .NET XML parser and recent perf improvements.