Class: Rimc::CacheEntry
- Inherits:
-
Struct
- Object
- Struct
- Rimc::CacheEntry
- Defined in:
- lib/rimc/cache_entry.rb
Instance Attribute Summary collapse
-
#cached_object ⇒ Object
Returns the value of attribute cached_object.
-
#expire_time ⇒ Object
Returns the value of attribute expire_time.
Instance Method Summary collapse
Instance Attribute Details
#cached_object ⇒ Object
Returns the value of attribute cached_object
2 3 4 |
# File 'lib/rimc/cache_entry.rb', line 2 def cached_object @cached_object end |
#expire_time ⇒ Object
Returns the value of attribute expire_time
2 3 4 |
# File 'lib/rimc/cache_entry.rb', line 2 def expire_time @expire_time end |
Instance Method Details
#expired? ⇒ Boolean
3 4 5 6 7 |
# File 'lib/rimc/cache_entry.rb', line 3 def expired? return false if expire_time.nil? Time.now > expire_time end |