class ExpiringHash(KeyT, ValueT)
- ExpiringHash(KeyT, ValueT)
- Reference
- Object
Defined in:
expiring_hash.crConstructors
-
.new(max_items : Int32 | Nil, expiry_period : Time::Span)
create a new expiring hash
Instance Method Summary
- #[](key : KeyT) : ValueT
- #[]=(key : KeyT, value : ValueT)
- #[]?(key : KeyT) : ValueT | Nil
-
#expiry_period : Time::Span
hash properties
-
#expiry_period=(expiry_period : Time::Span)
hash properties
-
#hash : Hash(KeyT, Tuple(Time, ValueT))
backing hash
-
#hash=(hash : Hash(KeyT, Tuple(Time, ValueT)))
backing hash
- #max_items : Int32 | Nil
- #max_items=(max_items : Int32 | Nil)