89 references to FindNextStartingPositionMode
System.Text.RegularExpressions (89)
System\Text\RegularExpressions\RegexCompiler.cs (41)
464case FindNextStartingPositionMode.LeadingString_LeftToRight: 465case FindNextStartingPositionMode.LeadingString_OrdinalIgnoreCase_LeftToRight: 466case FindNextStartingPositionMode.LeadingStrings_LeftToRight: 467case FindNextStartingPositionMode.LeadingStrings_OrdinalIgnoreCase_LeftToRight: 468case FindNextStartingPositionMode.FixedDistanceString_LeftToRight: 472case FindNextStartingPositionMode.LeadingString_RightToLeft: 476case FindNextStartingPositionMode.LeadingSet_LeftToRight: 477case FindNextStartingPositionMode.FixedDistanceSets_LeftToRight: 481case FindNextStartingPositionMode.LeadingSet_RightToLeft: 485case FindNextStartingPositionMode.LiteralAfterLoop_LeftToRight: 491goto case FindNextStartingPositionMode.NoSearch; 493case FindNextStartingPositionMode.NoSearch: 509case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Beginning: 519case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Start: 520case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Start: 530case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_EndZ: 551case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_End: 568case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Beginning: 583case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_EndZ: 608case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_End: 619case FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_End: 620case FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_EndZ: 623int extraNewlineBump = _regexTree.FindOptimizations.FindMode == FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_EndZ ? 1 : 0; 731int extraNewlineBump = _regexTree.FindOptimizations.FindMode == FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_EndZ ? 1 : 0; 757Debug.Assert(opts.FindMode is FindNextStartingPositionMode.LeadingString_LeftToRight or 758FindNextStartingPositionMode.LeadingString_OrdinalIgnoreCase_LeftToRight or 759FindNextStartingPositionMode.FixedDistanceString_LeftToRight or 760FindNextStartingPositionMode.LeadingStrings_LeftToRight or 761FindNextStartingPositionMode.LeadingStrings_OrdinalIgnoreCase_LeftToRight); 768if (opts.FindMode is FindNextStartingPositionMode.FixedDistanceString_LeftToRight && 777if (opts.FindMode is FindNextStartingPositionMode.LeadingStrings_LeftToRight or FindNextStartingPositionMode.LeadingStrings_OrdinalIgnoreCase_LeftToRight) 779LoadSearchValues(opts.LeadingPrefixes, opts.FindMode is FindNextStartingPositionMode.LeadingStrings_OrdinalIgnoreCase_LeftToRight ? StringComparison.OrdinalIgnoreCase : StringComparison.Ordinal); 784string literalString = opts.FindMode is FindNextStartingPositionMode.LeadingString_LeftToRight or FindNextStartingPositionMode.LeadingString_OrdinalIgnoreCase_LeftToRight ? 787LoadSearchValues([literalString], opts.FindMode is FindNextStartingPositionMode.LeadingString_OrdinalIgnoreCase_LeftToRight ? StringComparison.OrdinalIgnoreCase : StringComparison.Ordinal); 2692if (_regexTree!.FindOptimizations.FindMode == FindNextStartingPositionMode.LiteralAfterLoop_LeftToRight && 5391FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Beginning or 5392FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Start or 5393FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Start or 5394FindNextStartingPositionMode.LeadingAnchor_RightToLeft_End)
System\Text\RegularExpressions\RegexFindOptimizations.cs (48)
36(RegexNodeKind.Beginning, false) => FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Beginning, 37(RegexNodeKind.Beginning, true) => FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Beginning, 38(RegexNodeKind.Start, false) => FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Start, 39(RegexNodeKind.Start, true) => FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Start, 40(RegexNodeKind.End, false) => FindNextStartingPositionMode.LeadingAnchor_LeftToRight_End, 41(RegexNodeKind.End, true) => FindNextStartingPositionMode.LeadingAnchor_RightToLeft_End, 42(_, false) => FindNextStartingPositionMode.LeadingAnchor_LeftToRight_EndZ, 43(_, true) => FindNextStartingPositionMode.LeadingAnchor_RightToLeft_EndZ, 61FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_End : 62FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_EndZ; 74FindNextStartingPositionMode.LeadingString_RightToLeft : 75FindNextStartingPositionMode.LeadingString_LeftToRight; 114FindMode = FindNextStartingPositionMode.LeadingChar_RightToLeft; 124FindMode = FindNextStartingPositionMode.LeadingSet_RightToLeft; 137FindMode = FindNextStartingPositionMode.LeadingString_OrdinalIgnoreCase_LeftToRight; 149FindMode = FindNextStartingPositionMode.LeadingStrings_OrdinalIgnoreCase_LeftToRight; 179FindMode = FindNextStartingPositionMode.FixedDistanceString_LeftToRight; 214FindMode = FindNextStartingPositionMode.FixedDistanceChar_LeftToRight; 229FindNextStartingPositionMode.LeadingSet_LeftToRight : 230FindNextStartingPositionMode.FixedDistanceSets_LeftToRight; 240FindMode = FindNextStartingPositionMode.LiteralAfterLoop_LeftToRight; 249FindMode != FindNextStartingPositionMode.NoSearch || // there's a searching scheme available 253public FindNextStartingPositionMode FindMode { get; } = FindNextStartingPositionMode.NoSearch; 386case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Beginning: 396case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_Start: 408case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_EndZ: 418case FindNextStartingPositionMode.LeadingAnchor_RightToLeft_End: 430case FindNextStartingPositionMode.LeadingString_RightToLeft: 445case FindNextStartingPositionMode.LeadingChar_RightToLeft: 460case FindNextStartingPositionMode.LeadingSet_RightToLeft: 482Debug.Assert(FindMode == FindNextStartingPositionMode.NoSearch); 535case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Beginning: 544case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_Start: 553case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_EndZ: 562case FindNextStartingPositionMode.LeadingAnchor_LeftToRight_End: 571case FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_EndZ: 578case FindNextStartingPositionMode.TrailingAnchor_FixedLength_LeftToRight_End: 587case FindNextStartingPositionMode.LeadingString_LeftToRight: 602case FindNextStartingPositionMode.LeadingString_OrdinalIgnoreCase_LeftToRight: 617case FindNextStartingPositionMode.LeadingSet_LeftToRight: 661case FindNextStartingPositionMode.FixedDistanceChar_LeftToRight: 676case FindNextStartingPositionMode.FixedDistanceString_LeftToRight: 692case FindNextStartingPositionMode.LeadingStrings_LeftToRight: 693case FindNextStartingPositionMode.LeadingStrings_OrdinalIgnoreCase_LeftToRight: 710case FindNextStartingPositionMode.FixedDistanceSets_LeftToRight: 787case FindNextStartingPositionMode.LiteralAfterLoop_LeftToRight: 835Debug.Assert(FindMode == FindNextStartingPositionMode.NoSearch, $"Unexpected FindMode {FindMode}");