146 references to LexKind
System.Data.SqlXml (146)
System\Xml\Xsl\XPath\XPathParser.cs (53)
28
public Node Parse(XPathScanner scanner, IXPathBuilder<Node> builder,
LexKind
endLex) {
65
internal static bool IsStep(
LexKind
lexKind) {
67
lexKind ==
LexKind
.Dot ||
68
lexKind ==
LexKind
.DotDot ||
69
lexKind ==
LexKind
.At ||
70
lexKind ==
LexKind
.Axis ||
71
lexKind ==
LexKind
.Star ||
72
lexKind ==
LexKind
.Name // NodeTest is also Name
80
if (scanner.Kind ==
LexKind
.Slash) {
88
} else if (scanner.Kind ==
LexKind
.SlashSlash) {
115
if (scanner.Kind ==
LexKind
.Slash) {
118
} else if (scanner.Kind ==
LexKind
.SlashSlash) {
136
if (
LexKind
.Dot == scanner.Kind) { // '.'
139
if (
LexKind
.LBracket == scanner.Kind) {
142
} else if (
LexKind
.DotDot == scanner.Kind) { // '..'
145
if (
LexKind
.LBracket == scanner.Kind) {
151
case
LexKind
.Axis: // AxisName '::'
156
case
LexKind
.At: // '@'
160
case
LexKind
.Name:
161
case
LexKind
.Star:
171
while (
LexKind
.LBracket == scanner.Kind) {
220
case
LexKind
.Name :
235
scanner.PassToken(
LexKind
.LParens);
238
if (scanner.Kind !=
LexKind
.RParens) { // 'processing-instruction' '(' Literal ')'
239
scanner.CheckToken(
LexKind
.String);
248
scanner.PassToken(
LexKind
.RParens);
259
case
LexKind
.Star :
274
scanner.PassToken(
LexKind
.LBracket);
276
scanner.PassToken(
LexKind
.RBracket);
316
if (scanner.Kind ==
LexKind
.Minus) {
327
op = (scanner.Kind <=
LexKind
.LastOperator) ? (XPathOperator)scanner.Kind : XPathOperator.Unknown;
367
if (scanner.Kind ==
LexKind
.Union) {
372
while (scanner.Kind ==
LexKind
.Union) {
394
if (scanner.Kind ==
LexKind
.Slash) {
399
} else if (scanner.Kind ==
LexKind
.SlashSlash) {
424
while (scanner.Kind ==
LexKind
.LBracket) {
434
scanner.Kind ==
LexKind
.String ||
435
scanner.Kind ==
LexKind
.Number ||
436
scanner.Kind ==
LexKind
.Dollar ||
437
scanner.Kind ==
LexKind
.LParens ||
438
scanner.Kind ==
LexKind
.Name && scanner.CanBeFunction && !IsNodeType(scanner)
449
case
LexKind
.String:
453
case
LexKind
.Number:
457
case
LexKind
.Dollar:
460
scanner.CheckToken(
LexKind
.Name);
466
case
LexKind
.LParens:
469
scanner.PassToken(
LexKind
.RParens);
473
scanner.Kind ==
LexKind
.Name && scanner.CanBeFunction && !IsNodeType(scanner),
491
scanner.PassToken(
LexKind
.Name);
492
scanner.PassToken(
LexKind
.LParens);
494
if (scanner.Kind !=
LexKind
.RParens) {
497
if (scanner.Kind !=
LexKind
.Comma) {
498
scanner.CheckToken(
LexKind
.RParens);
System\Xml\Xsl\XPath\XPathScanner.cs (60)
65
private
LexKind
kind;
72
private
LexKind
prevKind;
82
this.kind =
LexKind
.Unknown;
88
public
LexKind
Kind { get { return kind; } }
124
Debug.Assert(kind ==
LexKind
.Name);
132
Debug.Assert(kind ==
LexKind
.Name);
140
if (kind ==
LexKind
.Eof) {
150
Debug.Assert(kind ==
LexKind
.String);
163
Debug.Assert(kind ==
LexKind
.Name);
170
Debug.Assert(kind ==
LexKind
.Axis);
194
kind =
LexKind
.Eof;
198
kind = (
LexKind
)curChar;
204
kind =
LexKind
.DotDot;
210
kind =
LexKind
.Dot;
216
kind =
LexKind
.ColonColon;
219
kind =
LexKind
.Unknown;
223
kind =
LexKind
.Star;
230
kind =
LexKind
.SlashSlash;
233
kind =
LexKind
.Slash;
237
kind =
LexKind
.Union;
241
kind =
LexKind
.Plus;
245
kind =
LexKind
.Minus;
249
kind =
LexKind
.Eq;
255
kind =
LexKind
.Ne;
258
kind =
LexKind
.Unknown;
264
kind =
LexKind
.Le;
267
kind =
LexKind
.Lt;
273
kind =
LexKind
.Ge;
276
kind =
LexKind
.Gt;
281
kind =
LexKind
.String;
287
kind =
LexKind
.Number;
296
kind =
LexKind
.Name;
352
kind =
LexKind
.Unknown;
360
LexKind
opKind;
363
opKind =
LexKind
.Multiply;
369
case "or" : opKind =
LexKind
.Or; break;
370
case "and": opKind =
LexKind
.And; break;
371
case "div": opKind =
LexKind
.Divide; break;
372
case "mod": opKind =
LexKind
.Modulo; break;
379
if (prevKind <=
LexKind
.LastOperator)
383
case
LexKind
.Slash:
384
case
LexKind
.SlashSlash:
385
case
LexKind
.At:
386
case
LexKind
.ColonColon:
387
case
LexKind
.LParens:
388
case
LexKind
.LBracket:
389
case
LexKind
.Comma:
390
case
LexKind
.Dollar:
399
this.kind =
LexKind
.Axis;
414
default : this.kind =
LexKind
.Name; return XPathAxis.Unknown;
478
public void PassToken(
LexKind
t) {
483
public void CheckToken(
LexKind
t) {
484
Debug.Assert(
LexKind
.FirstStringable <= t);
486
if (t ==
LexKind
.Eof) {
495
private string LexKindToString(
LexKind
t) {
496
Debug.Assert(
LexKind
.FirstStringable <= t);
498
if (
LexKind
.LastNonChar < t) {
504
case
LexKind
.Name : return "<name>";
505
case
LexKind
.String : return "<string literal>";
506
case
LexKind
.Eof : return "<eof>";
System\Xml\Xsl\Xslt\QilGenerator.cs (3)
1938
result = xpathParser.Parse(scanner, xpathBuilder,
LexKind
.Eof);
1974
result = xpathParser.Parse(scanner, xpathBuilder,
LexKind
.RBrace);
2063
result = xpathParser.Parse(scanner, xpathBuilder,
LexKind
.Eof);
System\Xml\Xsl\Xslt\XPathPatternParser.cs (28)
37
this.scanner.CheckToken(
LexKind
.Eof);
54
while (scanner.Kind ==
LexKind
.Union) {
68
case
LexKind
.Slash :
76
case
LexKind
.SlashSlash :
85
case
LexKind
.Name :
89
case
LexKind
.Slash :
93
case
LexKind
.SlashSlash :
122
scanner.PassToken(
LexKind
.LParens);
123
scanner.CheckToken(
LexKind
.String);
126
scanner.PassToken(
LexKind
.RParens);
130
scanner.PassToken(
LexKind
.LParens);
131
scanner.CheckToken(
LexKind
.String);
134
scanner.PassToken(
LexKind
.Comma);
135
scanner.CheckToken(
LexKind
.String);
138
scanner.PassToken(
LexKind
.RParens);
156
if (scanner.Kind ==
LexKind
.Slash) {
159
} else if (scanner.Kind ==
LexKind
.SlashSlash) {
181
case
LexKind
.Dot:
182
case
LexKind
.DotDot:
184
case
LexKind
.At:
188
case
LexKind
.Axis:
196
case
LexKind
.Name:
197
case
LexKind
.Star:
214
while (scanner.Kind ==
LexKind
.LBracket) {
221
while (scanner.Kind ==
LexKind
.LBracket) {
232
Debug.Assert(scanner.Kind ==
LexKind
.LBracket);
234
QilNode result = predicateParser.Parse(scanner, ptrnBuilder.GetPredicateBuilder(context),
LexKind
.RBracket);
235
Debug.Assert(scanner.Kind ==
LexKind
.RBracket);
System\Xml\Xsl\Xslt\XslAstAnalyzer.cs (2)
815
XslFlags result = xpathParser.Parse(scanner, this,
LexKind
.Eof);
846
result |= xpathParser.Parse(scanner, this,
LexKind
.RBrace);