Module: Fucko::Dictionary
- Defined in:
- lib/fucko/dictionary.rb
Constant Summary collapse
- WORDS =
["testicle", "ball", "ass", "cock", "slag", "shit", "gonad"]
Class Method Summary collapse
Class Method Details
.adjective ⇒ Object
18 19 20 21 22 23 24 25 26 27 |
# File 'lib/fucko/dictionary.rb', line 18 def self.adjective word = noun ending = 'ed' if word =~ /[aeiou][^aeiou]$/ "#{word}#{word[-1, 1]}#{ending}" else "#{word}#{ending}" end end |
.compound_adjective ⇒ Object
29 30 31 |
# File 'lib/fucko/dictionary.rb', line 29 def self.compound_adjective "#{noun}-#{adjective}" end |
.noun ⇒ Object
5 6 7 |
# File 'lib/fucko/dictionary.rb', line 5 def self.noun WORDS.sample end |
.plural_noun ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'lib/fucko/dictionary.rb', line 9 def self.plural_noun word = noun if word =~ /s$/ "#{word}es" else "#{word}s" end end |