Sha256: 44d921f61272e90c031f749c39230e71c92f4fa2dce8252ef7ec08153f92d8fe
Contents?: true
Size: 397 Bytes
Versions: 4
Compression:
Stored size: 397 Bytes
Contents
class Dictionaries def initialize @dictionaries = {} end def [](key) symbolized_key = key.to_sym if loaded?(symbolized_key) @dictionaries[symbolized_key] else @dictionaries[symbolized_key] = FileReader.read_dictionary(symbolized_key) end end def loaded?(key) @dictionaries.has_key?(key.to_sym) end def reset! @dictionaries = {} end end
Version data entries
4 entries across 4 versions & 2 rubygems
Version | Path |
---|---|
sevenwire-forgery-0.2.0 | lib/dictionaries.rb |
sevenwire-forgery-0.2.1 | lib/dictionaries.rb |
sevenwire-forgery-0.2.2 | lib/dictionaries.rb |
forgery-0.2.2 | lib/dictionaries.rb |