module Tins::AskAndSend
Public Instance Methods
Source
# File lib/tins/ask_and_send.rb, line 3 def ask_and_send(method_name, *args, &block) if respond_to?(method_name) __send__(method_name, *args, &block) end end
Source
# File lib/tins/ask_and_send.rb, line 9 def ask_and_send!(method_name, *args, &block) if respond_to?(method_name, true) __send__(method_name, *args, &block) end end
Source
# File lib/tins/ask_and_send.rb, line 15 def ask_and_send_or_self(method_name, *args, &block) if respond_to?(method_name) __send__(method_name, *args, &block) else self end end
Source
# File lib/tins/ask_and_send.rb, line 23 def ask_and_send_or_self!(method_name, *args, &block) if respond_to?(method_name, true) __send__(method_name, *args, &block) else self end end