{"id":22045242,"url":"https://github.com/nigelhorne/class-simple-cached","last_synced_at":"2026-02-13T22:34:31.754Z","repository":{"id":56837587,"uuid":"209167135","full_name":"nigelhorne/Class-Simple-Cached","owner":"nigelhorne","description":"Cache messages to an object","archived":false,"fork":false,"pushed_at":"2025-04-05T12:21:18.000Z","size":101,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-08T07:46:54.336Z","etag":null,"topics":["cpan","optimization","perl"],"latest_commit_sha":null,"homepage":"https://metacpan.org/pod/Class::Simple::Cached","language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nigelhorne.png","metadata":{"files":{"readme":"README.md","changelog":"Changes","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"nigelhorne","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":["https://www.paypal.com/paypalme/bandsman"]}},"created_at":"2019-09-17T22:22:20.000Z","updated_at":"2025-04-05T12:21:21.000Z","dependencies_parsed_at":"2022-09-12T11:51:31.844Z","dependency_job_id":"dcff6109-e75f-4f84-b4d1-ebd80955ff3a","html_url":"https://github.com/nigelhorne/Class-Simple-Cached","commit_stats":{"total_commits":48,"total_committers":4,"mean_commits":12.0,"dds":"0.27083333333333337","last_synced_commit":"2ed91fbb4adda97be602acc1135c8fe04bf1a89a"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FClass-Simple-Cached","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FClass-Simple-Cached/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FClass-Simple-Cached/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nigelhorne%2FClass-Simple-Cached/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nigelhorne","download_url":"https://codeload.github.com/nigelhorne/Class-Simple-Cached/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253025334,"owners_count":21842409,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpan","optimization","perl"],"created_at":"2024-11-30T13:12:21.867Z","updated_at":"2026-02-13T22:34:31.688Z","avatar_url":"https://github.com/nigelhorne.png","language":"Perl","funding_links":["https://github.com/sponsors/nigelhorne","https://www.paypal.com/paypalme/bandsman"],"categories":[],"sub_categories":[],"readme":"[![Kwalitee](https://cpants.cpanauthors.org/dist/Class-Simple-Cached.png)](http://cpants.cpanauthors.org/dist/Class-Simple-Cached)\n[![Tweet](https://img.shields.io/twitter/url/http/shields.io.svg?style=social)](https://twitter.com/intent/tweet?text=Cache+messages+to+an+object+#perl\u0026url=https://github.com/nigelhorne/class-simple-cached\u0026via=nigelhorne)\n\n# NAME\n\nClass::Simple::Cached - cache messages to an object\n\n# VERSION\n\nVersion 0.06\n\n# SYNOPSIS\n\nA subclass of [Class::Simple](https://metacpan.org/pod/Class%3A%3ASimple) which caches calls to read the status of an object that are otherwise expensive.\n\nIt is up to the caller to maintain the cache if the object comes out of sync with the cache,\nfor example,\nby changing its state.\n\nYou can use this class to create a caching layer for any object of any class\nthat works on objects with a get/set model,\nsuch as:\n\n    use Class::Simple;\n    my $obj = Class::Simple-\u003enew();\n    $obj-\u003eval('foo');\n    my $oldval = $obj-\u003eval();\n\n# SUBROUTINES/METHODS\n\n## new\n\nCreates a Class::Simple::Cached object.\n\nIt takes one mandatory parameter: cache,\nwhich is either an object which understands purge(), get() and set() calls,\nsuch as an [CHI](https://metacpan.org/pod/CHI) object;\nor is a reference to a hash where the return values are to be stored.\n\nIt takes one optional argument: object,\nwhich is an object that is taken to be the object to be cached.\nIf not given, an object of the class [Class::Simple](https://metacpan.org/pod/Class%3A%3ASimple) is instantiated\nand that is used.\n\n## can\n\nReturns if the embedded object can handle a message\n\n## isa\n\nReturns if the embedded object is the given type of object\n\n# AUTHOR\n\nNigel Horne, `\u003cnjh at bandsman.co.uk\u003e`\n\n# BUGS\n\nDoesn't work with [Memoize](https://metacpan.org/pod/Memoize).\n\nOnly works on messages that take no arguments.\nFor that, use [Class::Simple::Readonly::Cached](https://metacpan.org/pod/Class%3A%3ASimple%3A%3AReadonly%3A%3ACached).\n\nPlease report any bugs or feature requests to [https://github.com/nigelhorne/Class-Simple-Readonly/issues](https://github.com/nigelhorne/Class-Simple-Readonly/issues).\nI will be notified,\nand then you'll automatically be notified of the progress on your bug as I make changes.\n\n# SEE ALSO\n\n[Class::Simple](https://metacpan.org/pod/Class%3A%3ASimple), [CHI](https://metacpan.org/pod/CHI)\n\n# SUPPORT\n\nThis module is provided as-is without any warranty.\n\nYou can find documentation for this module with the perldoc command.\n\n    perldoc Class::Simple::Cached\n\nYou can also look for information at:\n\n- MetaCPAN\n\n    [https://metacpan.org/release/Class-Simple-Cached](https://metacpan.org/release/Class-Simple-Cached)\n\n- Source Repository\n\n    [https://github.com/nigelhorne/Class-Simple-Readonly-Cached](https://github.com/nigelhorne/Class-Simple-Readonly-Cached)\n\n- CPANTS\n\n    [http://cpants.cpanauthors.org/dist/Class-Simple-Cached](http://cpants.cpanauthors.org/dist/Class-Simple-Cached)\n\n- CPAN Testers' Matrix\n\n    [http://matrix.cpantesters.org/?dist=Class-Simple-Cached](http://matrix.cpantesters.org/?dist=Class-Simple-Cached)\n\n- CPAN Testers Dependencies\n\n    [http://deps.cpantesters.org/?module=Class::Simple::Cached](http://deps.cpantesters.org/?module=Class::Simple::Cached)\n\n# LICENCE AND COPYRIGHT\n\nAuthor Nigel Horne: `njh@bandsman.co.uk`\nCopyright (C) 2019-2025, Nigel Horne\n\nUsage is subject to licence terms.\nThe licence terms of this software are as follows:\nPersonal single user, single computer use: GPL2\nAll other users (including Commercial, Charity, Educational, Government)\nmust apply in writing for a licence for use from Nigel Horne at the\nabove e-mail.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnigelhorne%2Fclass-simple-cached","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnigelhorne%2Fclass-simple-cached","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnigelhorne%2Fclass-simple-cached/lists"}