Module: Fn

Extended by:
Fn
Included in:
Fn
Defined in:
lib/ex_aequo/kernel/fn.rb

Instance Method Summary collapse

Instance Method Details

#prefix_string(with) ⇒ Object



5
6
7
# File 'lib/ex_aequo/kernel/fn.rb', line 5

def prefix_string(with)
  ->(subject) { "#{with}#{subject}" }
end

#split_string(by = /\s+/) ⇒ Object



8
9
10
# File 'lib/ex_aequo/kernel/fn.rb', line 8

def split_string(by=/\s+/)
  ->(subject) {subject.split(by)}
end