Method: Wordlist::ListMethods#mutate_case

Defined in:
lib/wordlist/list_methods.rb

#mutate_caseEachCase

Lazily enumerates over every uppercase/lowercase variation of the word.

# foo # Foo # fOo # foO # FOo # FoO # fOO # FOO # bar # Bar # bAr # baR # BAr # BaR # bAR # BAR

Examples:

wordlist = Wordlist::Words["foo", "bar"]
wordlist.mutate_case.each do |word|
  puts word
end

Returns:

  • (EachCase)

    The lazy String#gsub modification of the wordlist.

Since:

  • 1.0.0



455
456
457
# File 'lib/wordlist/list_methods.rb', line 455

def mutate_case
  Modifiers::MutateCase.new(self)
end