Method: Randexp::Dictionary.words

Defined in:
lib/randexp/dictionary.rb

.words(options = {}) ⇒ Object



12
13
14
15
16
17
18
# File 'lib/randexp/dictionary.rb', line 12

def self.words(options = {})
  if options.has_key?(:length)
    words_by_length[options[:length]]
  else
    @@words ||= load_dictionary
  end
end