module Roda::RodaPlugins::Delegate::ClassMethods
def class_delegate(*meths)
def class_delegate(*meths) meths.each do |meth| define_method(meth){|*a, &block| self.class.public_send(meth, *a, &block)} end end
def request_delegate(*meths)
def request_delegate(*meths) meths.each do |meth| define_method(meth){|*a, &block| @_request.public_send(meth, *a, &block)} end end
def response_delegate(*meths)
def response_delegate(*meths) meths.each do |meth| define_method(meth){|*a, &block| @_response.public_send(meth, *a, &block)} end end