diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index a4a1a67bf..343e8c5f1 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -4,6 +4,7 @@ - Added export to context menu in asset manager - fix: Empty user-created version tags - fix: TagCloud (Keywords.pm) + - fix: Cache pod does not accurately reflect the Module usage - fix: XHTML 1.0 strict, FileUploadControl.js, resizable textarea - fix: undefined activity - Polls now use JSON instead of Storable to serialize graph config diff --git a/lib/WebGUI/Cache.pm b/lib/WebGUI/Cache.pm index 55d27a35e..eea879cde 100644 --- a/lib/WebGUI/Cache.pm +++ b/lib/WebGUI/Cache.pm @@ -31,6 +31,18 @@ A base class for all Cache modules to extend. =head1 SYNOPSIS use WebGUI::Cache; + + my $cache = WebGUI::Cache->new($session, "my app cache"); + my $cache = WebGUI::Cache->new($session, [ "my app", $assetId, $version ]); + + $cache->set($value); + $cache->setByHTTP("http://www.google.com/"); + + my $value = $cache->get; + + $cache->delete; + $cache->deleteChunk("my app cache"); + $cache->deleteChunk([ "my app", $assetId ]); =head1 METHODS @@ -106,7 +118,9 @@ A reference to the current session. =head3 key -A key to store the value under or retrieve it from. +A key to store the value under or retrieve it from. Can either be a scalar or an array reference of pieces (called +a composite key). Composite keys are useful for deleting a chunk (see deleteChunk()) of cache data all at once, and +for using multi-level identifiers like assetId/revisionDate. =head3 namespace