Skip to content

Instantly share code, notes, and snippets.

@gabe
Created December 17, 2009 18:40
Show Gist options
  • Save gabe/258927 to your computer and use it in GitHub Desktop.
Save gabe/258927 to your computer and use it in GitHub Desktop.
private static readonly Regex ExpressionArgumentPattern = new Regex(@"
^
\s*
(?<SelectorType>Current|SiteMarker) # Match one of these selector types.
\s*
(=
\s*
(?<SelectorArgument>.+?) # Optionally match a selector argument (one or more of any character, non-greedy).
)?
(
\s*
,
\s*
(?<ReturnType>Entity|Node|Url) # Optionally match one of these return types.
)?
\s*
$", RegexOptions.IgnoreCase | RegexOptions.IgnorePatternWhitespace | RegexOptions.ExplicitCapture);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment