RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Hosting Spotlight

Sponsors

Regular Expression Details

Title Test Find Pattern Title
Expression
(?:\s*)(?<=[-|/])(?<name>\w*)[:|=]("((?<value>.*?)(?<!\\)")|(?<value>[\w]*))
Description
Command line named argument parser which allows quoted values and includes &quot;\&quot;&quot; escape for quotes in a quoted value. Non-quoted values can be letter, space or underscore only. Argument names can be letter, space or underscore only. Argument delimiter can be &quot;-&quot; or &quot;/&quot; and name-value separator can be &quot;:&quot; or &quot;=&quot;. All arguments must be named. Spaces are not allowed in
Matches
/a:"value" -big="this -test:1\"23 is & $#@ _ your life" -test=th_3
Non-Matches
this does not match
Author Rating: The rating for this expression. Richard Hauer
Source
Your Rating
Bad Good

Enter New Comment

Title
 
Name
 
Comment
 
Spammers suck - we apologize. Please enter the text shown below to enable your comment (not case sensitive - try as many times as you need to if the first ones are too hard):

Existing User Comments

Copyright © 2001-2010, RegexAdvice.com | ASP.NET Tutorials