Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
LoopFocus.cs
Go to the documentation of this file.
3
4namespace System.Xml.Xsl.Xslt;
5
6internal struct LoopFocus : IFocus
7{
8 private readonly XPathQilFactory _f;
9
11
13
15
16 public bool IsFocusSet => _current != null;
17
19 {
20 _f = f;
21 _current = (_cached = (_last = null));
22 }
23
24 public void SetFocus(QilIterator current)
25 {
26 _current = current;
27 _cached = (_last = null);
28 }
29
31 {
32 return _current;
33 }
34
39
41 {
42 if (_last == null)
43 {
44 _last = _f.Let(_f.Double(0.0));
45 }
46 return _last;
47 }
48
49 public void EnsureCache()
50 {
51 if (_cached == null)
52 {
55 }
56 }
57
58 public void Sort(QilNode sortKeys)
59 {
60 if (sortKeys != null)
61 {
64 }
65 }
66
68 {
69 if (_last != null)
70 {
73 }
75 if (_last != null)
76 {
78 }
79 if (_cached != null)
80 {
82 }
83 return qilLoop;
84 }
85}
QilLoop Loop(QilNode variable, QilNode body)
QilIterator For(QilNode binding)
QilIterator Let(QilNode binding)
QilNode XsltConvert(QilNode expr, XmlQueryType t)
QilNode Sort(QilIterator iter, QilNode keys)
static readonly XmlQueryType DoubleX
void SetFocus(QilIterator current)
Definition LoopFocus.cs:24
QilLoop ConstructLoop(QilNode body)
Definition LoopFocus.cs:67
LoopFocus(XPathQilFactory f)
Definition LoopFocus.cs:18
void Sort(QilNode sortKeys)
Definition LoopFocus.cs:58
readonly XPathQilFactory _f
Definition LoopFocus.cs:8