public void Create(XPathNavigator context, XmlNavigatorFilter filter) {
// Start at root, which is always first node in the document
this.navCurrent = XmlQueryRuntime.SyncToNavigator(this.navCurrent, context);
this.navCurrent.MoveToRoot();
// If root node is not the ending node,
if (!this.navCurrent.IsSamePosition(context)) {
// Push root onto the stack if it is not filtered
if (!filter.IsFiltered(this.navCurrent))
this.stack.Push(this.navCurrent.Clone());
// Push all matching nodes onto stack
while (filter.MoveToFollowing(this.navCurrent, context))
this.stack.Push(this.navCurrent.Clone());
}
}