start_with? was introduced in 1.8.7, we need to support 1.8.5 and 1.8.6
Public Instance Methods
bytes(&block)click to toggle source
# File lib/mcollective/monkey_patches.rb, line 63defbytes(&block)
# This should not be necessary, really ...require'enumerator'returnto_enum(:each_byte) unlessblock_given?each_byte(&block)
end
start_with?(str)click to toggle source
# File lib/mcollective/monkey_patches.rb, line 4defstart_with?(str)
returnself[0.. (str.length-1)] ==strend