Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
IteratorFilter.cs
Go to the documentation of this file.
2
4
5internal sealed class IteratorFilter : XPathNodeIterator
6{
8
9 private readonly string _name;
10
11 private int _position;
12
14
15 public override int CurrentPosition => _position;
16
17 internal IteratorFilter(XPathNodeIterator innerIterator, string name)
18 {
19 _innerIterator = innerIterator;
20 _name = name;
21 }
22
29
30 public override XPathNodeIterator Clone()
31 {
32 return new IteratorFilter(this);
33 }
34
35 public override bool MoveNext()
36 {
37 while (_innerIterator.MoveNext())
38 {
40 {
41 _position++;
42 return true;
43 }
44 }
45 return false;
46 }
47}
IteratorFilter(XPathNodeIterator innerIterator, string name)
override XPathNodeIterator Clone()
readonly XPathNodeIterator _innerIterator