Sha256: 1420a6d3528a59e1b08ed2de0f1063f9fae6da43f594c979b902b85835e94bce
Contents?: true
Size: 474 Bytes
Versions: 9
Compression:
Stored size: 474 Bytes
Contents
module RProxy class CachePool def initialize @pool = {} @able_write = true end def []=(key, value) return value if !@able_write @pool[key] = value end def [](key) @pool[key] end def writable? @able_write end def disable_write! @able_write = false end def enable_write! @able_write = true end def flush tmp = @pool @pool = {} tmp end end end
Version data entries
9 entries across 9 versions & 1 rubygems