Module: O3o::Store
- Defined in:
- lib/o3o/store.rb
Class Method Summary collapse
Class Method Details
.list ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/o3o/store.rb', line 6 def self.list return @store if @store @store = {} @store[:available] = [] yan.each do |y| @store[:available].push y["tag"] y["tag"].split.each do |t| @store[t] = y["yan"] end end @store end |
.yan ⇒ Object
22 23 24 |
# File 'lib/o3o/store.rb', line 22 def self.yan @yan ||= JSON.load(IO.read(File.('../yan.json', __FILE__)))["list"] end |