Query: path::dispatcher::rule::regex
OS: debian
Section: 3pm
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
Path::Dispatcher::Rule::Regex(3pm) User Contributed Perl Documentation Path::Dispatcher::Rule::Regex(3pm)NAMEPath::Dispatcher::Rule::Regex - predicate is a regular expressionSYNOPSISmy $rule = Path::Dispatcher::Rule::Regex->new( regex => qr{^/comment(s?)/(d+)$}, block => sub { display_comment(shift->pos(2)) }, );DESCRIPTIONRules of this class use a regular expression to match against the path.ATTRIBUTESregex The regular expression to match against the path. It works just as you'd expect! The capture variables ($1, $2, etc) will be available in the match object as "->pos(1)" etc. "$`", $&, and "$'" are not restored. perl v5.12.4 2011-08-30 Path::Dispatcher::Rule::Regex(3pm)
Similar Topics in the Unix Linux Community |
---|
Adding the individual columns of a matrix. |
Introduction |
Detecting unused variables... |
One instance of comparing grep and awk |
Find columns in a file based on header and print to new file |