RubyGems.org

cnuregexp

1.0.0

cnuregexp allows tags to be placed inside a regex which function as labels for the matches. The matches within the MatchData object can then be accessed like a hash with the tag name as the key. cnuregexp also provides a greedy match which will return an array of all matches rather than just the first match. cnuregexp can also extract various data from an xml tag with the Regexp.xml_tag method. It uses Regexps to get the tag name, the attributes and their values, the tag content, and any other relevant data from an xml string. Lastly, cnuregexp allows commonly used regular expressions to be stored in a config file(lib/cnuregexp_config.yml) and accessed with Regexp.regular_expression_name notation eg. Regexp.ssn, Regexp.email_address. cnuregexp comes preloaded with a few common regular expressions which are located in lib/cnuregexp_config.yml.

installgem install cnuregexp
Authors

CashnetUSA, Brendan Baldwin

1,729 total downloads 1,728 for this version
Owners

73c2d5535dd6431f4932cecdf5fff6f93648f102978e465cf85aa8ff776d8c6b3aedb3c8a443d112ec588818fd5d3ed91b344af487bac9731d35c943d82a17caDe76a71b3d0047a43fc7b58151ce3057

Gemfile
gem 'cnuregexp', '~> 1.0.0'
Versions
  1. 1.0.0 May 22, 2007 (10 KB)
Runtime Dependencies
  1. hoe >= 1.2.0