Class: String

Inherits:
Object
  • Object
show all
Defined in:
lib/cabbage/string_extras.rb

Overview

a couple of extra methods for strings, to make things easier

Instance Method Summary collapse

Instance Method Details

#blank?Boolean

Returns:

  • (Boolean)


9
10
11
# File 'lib/cabbage/string_extras.rb', line 9

def blank?
	self !~ /\S/
end

#down_underObject



14
15
16
# File 'lib/cabbage/string_extras.rb', line 14

def down_under
	self.gsub("-", "_").downcase	
end