Method: PEROBS::Cache#initialize
- Defined in:
- lib/perobs/Cache.rb
#initialize(bits = 16) ⇒ Cache
Create a new Cache object.
43 44 45 46 47 48 49 50 |
# File 'lib/perobs/Cache.rb', line 43 def initialize(bits = 16) @bits = bits # This mask is used to access the _bits_ least significant bits of the # object ID. @mask = 2 ** bits - 1 # Initialize the read and write cache reset end |