GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  TEXT::XSLATE::BRIDGE::STAR (3)

.ds Aq ’

NAME

Text::Xslate::Bridge::Star - Selection of common utilities for templates

CONTENTS

SYNOPSIS



    use Text::Xslate;

    my $tx = Text::Xslate->new(
        module => [Text::Xslate::Bridge::Star],
    );



DESCRIPTION

This module provides a selection of utilities for templates.

FUNCTIONS

CWlc($str)

Returns a lower-cased version of $str. The same as CORE::lc(), but returns undef if $str is undef.

See lc in perldoc for details.

CWuc($str)

Returns a upper-cased version of $str. The same as CORE::uc(), but returns undef if $str is undef.

See uc in perldoc for details.

CWsubstr($str, $offset, $len)

Extracts a substring out of $str and returns it. The same as CORE::substr(), but returns undef if $str is undef.

See substr in perldoc for details.

CWsprintf($fmt, args...)

Returns a string formatted by the CORE::sprintf(). $fmt must be a defined value.

See sprintf in perldoc for details.

CWrx($regex_pattern)

Compiles $regex_patter as a regular expression and return the regex object. You can pass a regex object to match() or replace() described bellow. The same as qr// operator in Perl.

CWmatch($str, $pattern)

Tests if $str matches $pattern. $pattern may be a string or a regex object.

Like $str =~ $pattern in Perl but you have to pass a regex object explicitly if you can use regular expressions.

Examples:



    : match("foo bar baz", "foo")     ? "true" : "false" # true
    : match("foo bar baz", "f..")     ? "true" : "false" # false
    : match("foo bar baz", rx("f..")) ? "true" : "false" # true



CWreplace($str, $pattern, $replacement)

Replaces all the $patterns in $str with $replacements. Like as $str =~ s/$pattern/$replacement/g but you have to pass a regex object explicitly if you can use regular expressions.

CWsplit($str [, $pattern [, $limit]])

Splits the string $str into a list of strings and returns the list.

SEE ALSO

Text::Xslate

Text::Xslate::Bridge

perlfunc

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 TEXT::XSLATE::BRIDGE::STAR (3) 2015-08-28

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.