Class: Goat::Static
Class Method Summary collapse
Class Method Details
.press=(h) ⇒ Object
10 11 12 13 |
# File 'lib/goat/static.rb', line 10 def press=(h) @press = YAML.load_file(h[:file]) @rsrc = h[:resource] end |
.press_enabled? ⇒ Boolean
6 7 8 |
# File 'lib/goat/static.rb', line 6 def press_enabled? not @press.nil? end |
.press_resource ⇒ Object
19 20 21 |
# File 'lib/goat/static.rb', line 19 def press_resource @rsrc end |
.pressed?(c) ⇒ Boolean
15 16 17 |
# File 'lib/goat/static.rb', line 15 def pressed?(c) @press[:classes].include?(c.to_s) end |