Really simple caching by attaching an expiration date to attributes. The ExpirationDate module adss two methods to a class -- expiring_attr and expiring_class_attr. These two methods are used to declare attributes in the instance and in the class, respectively, that will expire after some period of seconds have elapsed. The attribute is re-initialized from the given block after it has expired. This is a very simple form of caching.
Required Ruby Version
None
Authors
Tim Pease
Versions
-
1.1.0
-
source
- 1.1.0 source August 25, 2008This gem version was imported to RubyGems.org on July 25, 2009. The date displayed was specified by the author in the gemspec. (15 KB)
-
-
1.0.1
-
source
- 1.0.1 source August 23, 2008This gem version was imported to RubyGems.org on July 25, 2009. The date displayed was specified by the author in the gemspec. (15 KB)
-
-
1.0.0
-
source
- 1.0.0 source August 22, 2008This gem version was imported to RubyGems.org on July 25, 2009. The date displayed was specified by the author in the gemspec. (15 KB)
-