Class: GameFaqs::Caching::Store
- Inherits:
-
Hash
- Object
- Hash
- GameFaqs::Caching::Store
- Defined in:
- lib/gamefaqs/caching.rb
Instance Attribute Summary collapse
-
#keys ⇒ Object
readonly
Returns the value of attribute keys.
Instance Method Summary collapse
- #[]=(key, value) ⇒ Object
-
#clean! ⇒ Object
retain only second half of cache if it gets to big.
-
#initialize(*args) ⇒ Store
constructor
A new instance of Store.
Constructor Details
#initialize(*args) ⇒ Store
Returns a new instance of Store.
6 7 8 9 |
# File 'lib/gamefaqs/caching.rb', line 6 def initialize(*args) super(*args) @keys = [] end |
Instance Attribute Details
#keys ⇒ Object (readonly)
Returns the value of attribute keys.
4 5 6 |
# File 'lib/gamefaqs/caching.rb', line 4 def keys @keys end |
Instance Method Details
#[]=(key, value) ⇒ Object
11 12 13 14 15 |
# File 'lib/gamefaqs/caching.rb', line 11 def []=(key, value) @keys << key clean! super end |