Rediscovery of Regular Expressions
This collection of links is brought to you in order to rediscover with me the fabulous world of regular expressions. I am currently using a lot of regexp in the typographic engine I am building. Books by O'Reilly:
- Mastering Regular Expressions, Second Edition by Jeffrey E. F. Friedl (official website here): the bible, which I own [buy by Amazon.com];
- Regular Expressions Pocket Reference by Tony Stubblebine: the quick reference [buy by Amazon.com].
On Perldoc.com, a huge site with Perl documentation:
- references: perlre - Perl regular expressions (the main reference for Perl Regular Expressions) and perlreref - Perl Regular Expressions Reference (a concise reference on Perl RE);
- tutorials: perlrequick - Perl regular expressions quick start (a quick start guide for Perl RE) and perlretut - Perl regular expressions tutorial (a long tutorial);
- FAQ: perlfaq6 - Regular Expressions;
- others: Regexp Quote-Like Operators (about quote-like operators that apply to pattern matching and related activities) and Gory details of parsing quoted constructs (dealing with quoted constructs in Perl).
Websites:
- Regular-Expressions.info: a very complete website.
- RegExLib.com – Regular Expression Library is a repository of expressions for particular tasks (actually this library is used by many RE tester tools, and RegExLib.com offers its own online RE test tools). Have a look at the excellent collection of RE patterns.
Regular Expressions testing tools:
- The Regulator (.NET) – the best I have tested;
- Espresso (.NET), introducing article on CodeProject (but talking about the previous version) – not tested yet;
- JRegexpTester (Java) – interesting but not the best;
- The Regex Coach (Windows and Linux) – tested but not so good;
- RegexDesigner.NET (.NET), GotDotNet workspace here – not tested;
- Regular Expression Workbench (.NET) – not tested.
Java packages (excepts from regex.info's Links to Java Regex Packages):
- Sun
java.util.regex
(used on the same project as Jakarta Regexp, but Sun implementation was limited); - Jakarta Apache ORO (only used once);
- Jakarta Apache Regexp (the one I currently use);
- XML Apache Xerces
org.apache.xerces.utils.regex
(never used) – IBMcom.ibm.regex
aka Regex4J is not available anymore; - JRegex (never used but seems to be worth it);
gnu.regexp
(used once on the same project as Jakarta Regexp, but there was a problem with this GNU package that I have not met in the Jakarta one);com.stevesoft.pat
(never used).
PHP can use Perl Compatible Regular Expressions (PCRE).
More: the e-x-c-e-l-l-e-n-t article Marshall McLuhan vs. Marshalling Regular Expressions by Andy Oram.
“Regular expressions extend the reach of text, and therefore inexorably change how we sense the text.”
Posted by Jean-Philippe on December 23, 2004 1 Comments, 171 TrackBacks