Parse::RandGen::Regexp 0.202
Sponsored Links
Parse::RandGen::Regexp 0.202 Ranking & Summary
File size:
0.025 MB
Platform:
Any Platform
License:
Perl Artistic License
Price:
Downloads:
1039
Date added:
2006-12-19
Publisher:
Jeff Dutton
Parse::RandGen::Regexp 0.202 description
Parse::RandGen::Regexp is a Perl module for regular expression Condition element.
Regexp is a Condition element that matches the given compiled regular expression. For picking random data, the regular expression is parsed into its component Subrules, Literals, CharClasses, etc.... Therefore, the pick functionality for a regular expression is ultimately the same as the pick functionality of a Rule (including the limitations w/r to greediness - see Rule).
Regexp is also useful as a standalone class. It supports captures (named and indexed), which can be referenced in a call to the pick() function to force the captures to match the specified data, while leaving the rest of the data to be generated randomly.
METHODS
new
Creates a new Regexp. The first argument (required) is the regular expression element (e.g. qr/foo(bar|baz)+d{1,10}/). All other arguments are named pairs.
element
Returns the Regexp element (i.e. the compiled regular expression itself).
numCaptures
Returns the number of captures (e.g. $1, $2, ...$n) in the regular expression.
nameCapture
Give names to capture numbers for the regular expression. The arguments to this function are capture# => "name" pairs (e.g. nameCapture(1=>"directory", 2=>"file", 3=>"extension")).
capture
Returns the Rule object that represents the specified capture. The capture can be specified by number or by name (the name is set by the nameCapture() function).
pick
Randomly generate data (text) that matches (or does not) this regular expression.
Takes a "match" boolean argument that specifies whether to match the regular expression or deliberately not match it.
Also takes a "captures" hash argument that has pairs of capture numbers (or names) and their desired value. This allows the generated data to have user-specified constraints while allowing the rest of the regular expression to choose random data. If "match" is false, the user-specified "captures" values are still used (which may cause the data to match even though it was not supposed to).
Example:
$re->pick(match=>1,
captures=>{ 1=>"http", 2=>"www", 3=>"yahoo", 4=>"com" });
Regexp is a Condition element that matches the given compiled regular expression. For picking random data, the regular expression is parsed into its component Subrules, Literals, CharClasses, etc.... Therefore, the pick functionality for a regular expression is ultimately the same as the pick functionality of a Rule (including the limitations w/r to greediness - see Rule).
Regexp is also useful as a standalone class. It supports captures (named and indexed), which can be referenced in a call to the pick() function to force the captures to match the specified data, while leaving the rest of the data to be generated randomly.
METHODS
new
Creates a new Regexp. The first argument (required) is the regular expression element (e.g. qr/foo(bar|baz)+d{1,10}/). All other arguments are named pairs.
element
Returns the Regexp element (i.e. the compiled regular expression itself).
numCaptures
Returns the number of captures (e.g. $1, $2, ...$n) in the regular expression.
nameCapture
Give names to capture numbers for the regular expression. The arguments to this function are capture# => "name" pairs (e.g. nameCapture(1=>"directory", 2=>"file", 3=>"extension")).
capture
Returns the Rule object that represents the specified capture. The capture can be specified by number or by name (the name is set by the nameCapture() function).
pick
Randomly generate data (text) that matches (or does not) this regular expression.
Takes a "match" boolean argument that specifies whether to match the regular expression or deliberately not match it.
Also takes a "captures" hash argument that has pairs of capture numbers (or names) and their desired value. This allows the generated data to have user-specified constraints while allowing the rest of the regular expression to choose random data. If "match" is false, the user-specified "captures" values are still used (which may cause the data to match even though it was not supposed to).
Example:
$re->pick(match=>1,
captures=>{ 1=>"http", 2=>"www", 3=>"yahoo", 4=>"com" });
Parse::RandGen::Regexp 0.202 Screenshot
Advertisements
Parse::RandGen::Regexp 0.202 Keywords
RandGen
Regexp 0.202
regular expression
Perl module
regular
expression
element
data
match
captures
Parse::RandGen::Regexp
ParseRandGenRegexp
Parse::RandGen::Regexp 0.202
Libraries
Programming
Bookmark Parse::RandGen::Regexp 0.202
Parse::RandGen::Regexp 0.202 Copyright
WareSeeker periodically updates pricing and software information of Parse::RandGen::Regexp 0.202 full version from the publisher, so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of Parse::RandGen::Regexp 0.202 Edition. Download links are directly from our publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed
Featured Software
Want to place your software product here?
Please contact us for consideration.
Contact WareSeeker.com
Related Information
regular expressions
regular expression tutorial
regular expression tester
regular expression examples
regular expression syntax
regular expression reference
javascript regular expression
regular expression tool
perl regular expression
regular expressions php
regular expression example
regular expression library
extended regular expression
mastering regular expressions
regular expressions guide
perl regular expressions
regular expressions second
regular expression cheat sheet
Related Software
Sub::Regex is a Perl module to create synonymous subroutines. Free Download
X12::Parser::Readme is a Perl module for understanding configuration (cf) files for X12::Parser. Free Download
Tail server allows you to export the output of a Free Download
GRegExp Explorer is a graphical regular expression explorer based on the PCRE regular expression library. Free Download
RegExplorer project is a regular Expression Explorer. Free Download
perlrebackslash is a module with Perl Regular Expression Backslash Sequences and Escapes. Free Download
Regexp::Assemble is Perl module to assemble multiple Regular Expressions into a single RE. Free Download
ShiftJIS::Regexp contains regular expressions in Shift-JIS. Free Download
Latest Software
Popular Software
Favourite Software