2 // System.Xml.XPath.XPathNodeIterator
5 // Jason Diamond (jason@injektilo.org)
7 // (C) 2002 Jason Diamond http://injektilo.org/
12 namespace System.Xml.XPath
14 public abstract class XPathNodeIterator : ICloneable
16 private int _count = -1;
20 protected XPathNodeIterator ()
28 public virtual int Count
34 // compute and cache the count
35 XPathNodeIterator tmp = Clone ();
36 while (tmp.MoveNext ())
38 _count = tmp.CurrentPosition;
44 public abstract XPathNavigator Current { get; }
46 public abstract int CurrentPosition { get; }
52 public abstract XPathNodeIterator Clone ();
54 object ICloneable.Clone ()
59 public abstract bool MoveNext ();