def create_methods(locals = {})
        locals = {} unless locals

        klass = class << self; self; end

        locals.each do |method_name, value|
          klass.send(:define_method, method_name) do
            value
          end
        end
      end
def create_methods(locals = {})
        locals = {} unless locals

        klass = class << self; self; end

        locals.each do |method_name, value|
          klass.send(:define_method, method_name) do
            value
          end
        end
      end
create_methods: Creates instance methods using locals hash's keys and values.

 == Options

 * <tt>locals</tt> - Hash used to create helper methods available for the ActionParameter instance. Methods will be named using the hash keys and they'll return the hash values.

 == Examples

     create_methods(current_user: @user, another_key: @another_variable)

   Will create 'current_user' and 'another_key' instance methods.
   This methods will be aviable only in the current parameter class where create_method was called.
   'current_user'    will return @user.
   'another_key'     will return @another_variable