Module: Portero::SearchProvider::ClassMethods

Defined in:
lib/portero/search_provider.rb

Instance Method Summary collapse

Instance Method Details

#api_not_implemented(klass) ⇒ Object



10
11
12
13
14
# File 'lib/portero/search_provider.rb', line 10

def api_not_implemented(klass)
  caller.first.match(/in \`(.+)\'/)
  method_name = $1
  raise InterfaceNotImplementedError.new("#{klass.class.name} needs to implement '#{method_name}'!")
end

#requires_option(key) ⇒ Object



16
17
18
# File 'lib/portero/search_provider.rb', line 16

def requires_option(key)
  required_options << key
end