|
NAMEYAPE::Regex::Explain - explanation of a regular expressionVERSIONThis document refers to YAPE::Regex::Explain version 4.01.SYNOPSISuse YAPE::Regex::Explain; my $exp = YAPE::Regex::Explain->new($REx)->explain; "YAPE" MODULESThe "YAPE" hierarchy of modules is an attempt at a unified means of parsing and extracting content. It attempts to maintain a generic interface, to promote simplicity and reusability. The API is powerful, yet simple. The modules do tokenization (which can be intercepted) and build trees, so that extraction of specific nodes is doable.DESCRIPTIONThis module merely sub-classes "YAPE::Regex", and produces a rather verbose explanation of a regex, suitable for demonstration and tutorial purposes.Methods for "YAPE::Regex::Explain"
EXAMPLESPrint the full explanation for the regex "\Q[abc]\E\d+", compiling it first:print YAPE::Regex::Explain->new(qr/\Q[abc]\E\d+/)->explain(); Print the explanation for the regex "\w[a-f]*", without comments: print YAPE::Regex::Explain->new('\w[a-f]*')->explain('silent'); Print the explanation for a multi-line regex: my $re = qr{ (foo|bar) # just a comment \d+ / }ix; print YAPE::Regex::Explain->new($re)->explain(); LIMITATIONSThere is no support for regular expression syntax added after Perl version 5.6, particularly any constructs added in 5.10. For examples, refer to:<http://perldoc.perl.org/perl5100delta.html#Regular-expressions> DEPENDENCIESYAPE::RegexAUTHORThe original author is Jeff "japhy" Pinyan (CPAN ID: PINYAN).Gene Sullivan (gsullivan@cpan.org) is a co-maintainer. LICENSEThis module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See perlartistic.
Visit the GSP FreeBSD Man Page Interface. |