Module: Bazaar
- Defined in:
- lib/bazaar.rb,
lib/bazaar/version.rb
Constant Summary collapse
- VERSION =
"0.0.2"
Class Method Summary collapse
- .adj ⇒ Object
- .get_item(filename) ⇒ Object
- .heroku ⇒ Object
- .item ⇒ Object
- .object ⇒ Object
- .super_adj ⇒ Object
- .super_item ⇒ Object
- .super_object ⇒ Object
Class Method Details
.adj ⇒ Object
7 8 9 |
# File 'lib/bazaar.rb', line 7 def self.adj get_item("adj").humanize end |
.get_item(filename) ⇒ Object
25 26 27 |
# File 'lib/bazaar.rb', line 25 def self.get_item(filename) File.read(File.("../bazaar/#{filename}.txt", __FILE__)).split("\n").sample end |
.heroku ⇒ Object
22 23 24 |
# File 'lib/bazaar.rb', line 22 def self.heroku get_item("superadj") + '-' + get_item("superitems") + '-' + rand(0-9999).to_s end |
.item ⇒ Object
4 5 6 |
# File 'lib/bazaar.rb', line 4 def self.item get_item("items").humanize end |
.object ⇒ Object
10 11 12 |
# File 'lib/bazaar.rb', line 10 def self.object (get_item("adj") + ' ' + get_item("items")).humanize end |
.super_adj ⇒ Object
16 17 18 |
# File 'lib/bazaar.rb', line 16 def self.super_adj get_item("superadj").humanize end |
.super_item ⇒ Object
13 14 15 |
# File 'lib/bazaar.rb', line 13 def self.super_item get_item("superitems").humanize end |
.super_object ⇒ Object
19 20 21 |
# File 'lib/bazaar.rb', line 19 def self.super_object (get_item("superadj") + ' ' + get_item("superitems")).humanize end |