Text::T...okenizer(3)
π Text::T...okenizer π
okay so bestie, welcome to a page from the User Contributed Perl Documentation collection, and the page is literally called Text::T...okenizer(3). yes the title is abbreviated like that. no I don't know why. we move. π«Ά
β¨ NAME β¨
Text::Template::Simple::Tokenizer β the tokenizer, the moment, the main character π
π VERSION π
version 0.91 β¨
π¦ SYNOPSIS π¦
use strict;
use warnings;
use Text::Template::Simple::Constants qw( :token );
use Text::Template::Simple::Tokenizer;
my $t = Text::Template::Simple::Tokenizer->new( $start_delim, $end_delim );
foreach my $token ( @{ $t->tokenize( $raw_data ) } ) {
printf "Token type: %s\n", $token->[TOKEN_ID];
printf "Token data: %s\n", $token->[TOKEN_STR];
}
like. look at her. building an object, tokenizing the raw data, printing the TOKEN_ID and the TOKEN_STR of every token. that's the whole vibe. slay. π
π DESCRIPTION π
so basically it splits the input into tokens using the delimiter pair you defined. that's it. that's the job. she takes your big messy string and hands you back lil token pieces. periodt. β¨
π NAME π
Text::Template::Simple::Tokenizer - "Tokenizer"
(yes bestie, a second NAME section. the POD said so. we don't question the POD. π)
π METHODS π
π§ new π§
the object constructor, the moment of creation, the birth of the tokenizer π«
she accepts two parameters, and the order matters fr fr:
start_delimiterend_delimiter
that's the order. don't flip it. π
π tokenize π
splits the input into tokens using the delimiter pair you supplied when you made the object βοΈ
she accepts a single parameter: the raw template string. that's it. one (1) argument. no more. she's low maintenance like that. π
πΈ ESCAPE METHODS πΈ
the escape girls. they escape things. iconic behaviour honestly. π«Ά
tildeβ escapes the tilde character. that's the~bestie. she said not today. β¨quoteβ escapes double quotes. the"ones. she's got them handled too. π
π AUTHOR π
Burak Gursoy <burak@cpan.org> π
π COPYRIGHT AND LICENSE π
This software is copyright (c) 2004 by Burak Gursoy.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. π
aaaand that's the page bestie π this was perl v5.42.0, dated 2025-07-25, and the header up top said Text::T...okenizer(3) β go tokenize something cute, ily, bye π¦β¨
π¦ where this page comes from
- fedora 43: perl-Text-Template-Simple 0.91-22.fc43 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms