Cache:...ryCache(3pm)
π Cache::SizeAwareMemoryCache π
okay bestie, welcome to the Cache:...ryCache(3pm) page β yes that's the manual name, it got squished, don't worry about it, we move. this is the perl manpage for Cache::SizeAwareMemoryCache and it's genuinely so useful. let's get into it π«Ά
β¨ NAME β¨
Cache::SizeAwareMemoryCache</ppurple> β it extends Cache::MemoryCache. that's it, that's the name, and honestly it ate. π
πΈ DESCRIPTION πΈ
so the SizeAwareMemoryCache class is that girl: it adds the ability to dynamically limit the size (in bytes) of a memory based cache. not me being able to cap my cache at a byte count, lowkey iconic.
and it doesn't stop there β this class also implements the SizeAwareCache interface, which means it hands you the 'max_size' option and the 'limit_size( $size )' method. two gifts, one class. π
β SYNOPSIS β
here's the vibe, copy-paste ready, fr fr:
use Cache::SizeAwareMemoryCache;
my $cache =
new Cache::SizeAwareMemoryCache( { 'namespace' => 'MyNamespace',
'default_expires_in' => 600,
'max_size' => 10000 } );
look at that 'max_size' => 10000. we love a byte limit. β¨
π¦ METHODS π¦
the API documentation lives over in Cache::Cache and Cache::SizeAwareCache β go check those besties, they have the receipts. π
π OPTIONS π
same deal, babes: the standard options are documented in Cache::Cache and Cache::SizeAwareCache. no gatekeeping, just redirecting. π
π PROPERTIES π
and for the default properties? you already know. Cache::Cache and Cache::SizeAwareCache. the holy trinity of "go read this other page". π
π₯ SEE ALSO π₯
Cache::CacheCache::SizeAwareCacheCache::MemoryCache
three icons, one list. go read them all, iykyk. π
π AUTHOR π
- Original author: DeWitt Clinton
<dewitt@unto.net> - Last author:
$Author: dclinton $ - Copyright (C) 2001-2003 DeWitt Clinton
give it up for DeWitt, main character energy since 2001. π«Ά
and that's the whole page bestie, no notes, you understood it perfectly. this was Cache:...ryCache(3pm) as rendered by perl v5.34.0 on 2022-06-30 β date stamped and everything, periodt. go forth and size-limit your cache responsibly πβ¨π
π¦ where this page comes from
- debian bookworm: libcache-cache-perl 1.08-3 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- debian trixie: libcache-cache-perl 1.08-3 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- ubuntu noble: libcache-cache-perl 1.08-3 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- ubuntu resolute: libcache-cache-perl 1.08-3 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- ubuntu stonking: libcache-cache-perl 1.08-3 Β· 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