Text::T...e::Cache(3)
β¨ NAME β¨
okay bestie, say hi to Text::Template::Simple::Cache π this is the page from the Text::T...e::Cache(3) manual, and it's literally the cache manager for Text::Template::Simple. that's the whole vibe. no cap.
πΈ VERSION πΈ
version 0.91 β yes queen, we're on 0.91 π
π¦ SYNOPSIS π¦
TODO
not me leaving this blank π the docs said TODO and honestly? same energy. it's giving "we'll fill this in later" and later never came π
π DESCRIPTION π
so what is this? it's the cache manager for Text::Template::Simple. that's it, that's the description. it manages the cache. iconic behaviour, honestly π
π NAME π
Text::Template::Simple::Cache β Cache manager. she does exactly what it says on the tin, periodt β¨
π METHODS π
π new PARENT_OBJECT
Constructor, aka the birth of a legend β¨ it accepts a Text::Template::Simple object as the parameter. hand it your template object and you're off π«Ά
π type
Returns the type of the cache. just... tells you what kind of cache you got. lowkey useful, highkey simple π
π reset
Resets the in-memory cache and deletes all cache files, if you are using a disk cache. π§Ήβ¨
heads up bestie β if you're on a disk cache, this one goes scorched earth. everything in memory, every cache file on disk. gone. know what you're doing before you call it π
π dumper TYPE
$template->cache->dumper( $type, \%opt );
TYPE can either be structure or ids. and dumper accepts some arguments as a hash reference:
$template->cache->dumper( $type, \%opt );
the options you can drop in that hashref:
varnameβ controls the name of the dumped structure. you get to name the thing, main character privileges πno_deparseβ if you set this to a true value, "deparsing" will be disabled. bye deparse πstructureβ returns a string version of the dumped in-memory or disk-cache. the cache is dumped viaData::Dumper, and the "Deparse" option is enabled for in-memory cache.
real talk π«Ά early versions ofData::Dumperdon't have aDeparsemethod, so you may need to upgrade yourData::Dumperor disable "deparsing" if you want to use this method. don't say nobody warned you π
idsβ returns a list including the names (ids) of the templates in the cache. a lil guest list of everything chilling in there π
π id
Gets/sets the cache id. get it, set it, whatever you need, bestie π
π size
Returns the total cache (disk or memory) size in bytes. π
if memory cache is used, then you must haveDevel::Sizeinstalled on your system to get the size of the data structure inside memory. noDevel::Size? no number. that's the rule π€·
π has data => TEMPLATE_DATA and has id => TEMPLATE_ID
this method can be called with the data or the id named parameter. and if you use the two together, id will be used β id wins, always, no debate π
if ( $template->cache->has( id => 'e369853df766fa44e1ed0ff613f563bd' ) ) {
print "ok!";
}
or
if ( $template->cache->has( data => q~Foo is <%=$bar%>~ ) ) {
print "ok!";
}
π hit
TODO
once again, TODO π the mystery method. she's giving "coming soon" and honestly we respect the suspense
π populate
TODO
and ANOTHER TODO π two mystery methods in one page, this is truly the unhinged era of documentation and i'm obsessed
π AUTHOR π
Burak Gursoy <burak@cpan.org> β thank you for your service legend π«Ά
π 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. slay, free software rights fr fr π
okay that's the whole page, you ate it, you're welcome π
β¨ this was Text::T...e::Cache(3) β perl v5.42.0, dated 2025-07-25, and it's genuinely giving iconic. mwah ππ¦π
π¦ 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