String::Gsub - regex on string object
Version 0.02
use String::Gsub qw(gstr); print gstr("abcabc")->gsub(qr/b/,sub{uc$1}); # ==> "aBcaBc" print gstr("hw")->gsub(qr/h/,"Hello")->gsub(qr/w/,"World"); # ==> "HelloWorld"
This module can export gstr.
gstr
Alias for String::Gsub->new($str);
String::Gsub->new($str)
Create new instance.
process global substitute, and return new object.
like gsub, but replace self object and return itself.
process one substitute, and return new object.
like sub, but replace self object and return itself.
returns string value contained in.
YAMASHINA Hio, <hio at cpan.org>
<hio at cpan.org>
Please report any bugs or feature requests to bug-string-gsub at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=String-Gsub. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-string-gsub at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc String::Gsub
You can also look for information at:
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/String-Gsub
CPAN Ratings
http://cpanratings.perl.org/d/String-Gsub
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=String-Gsub
Search CPAN
http://search.cpan.org/dist/String-Gsub
String::Gsub, String::Gsub::Functions
Copyright 2006 YAMASHINA Hio, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
To install String::Gsub, copy and paste the appropriate command in to your terminal.
cpanm
cpanm String::Gsub
CPAN shell
perl -MCPAN -e shell install String::Gsub
For more information on module installation, please visit the detailed CPAN module installation guide.