InDocumentOrder

The InDocumentOrder operator can be called on a sequence of nodes and returns a sequence containing each source node's child nodes in document order.

Prototypes

The InDocumentOrder operator has one prototype.

Example. The Only InDocumentOrder Prototype
public static IEnumerable<T> InDocumentOrder<T> (
  this IEnumerable<T> source
) where T : XNode

This version is called on a sequence of a specified type, which must be nodes or some type derived from nodes, and returns a sequence of that same type containing each source node's child nodes in document order.

Examples

This is a fairly odd operator. For this example, I need a source sequence of nodes. Since I want to see some nodes that are not elements in addition to elements, ...

Get Pro LINQ: Language Integrated Query in C# 2008 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.