Module: Eapi::Methods::Types::IsAnOtherTypeMethods

Defined in:
lib/eapi/methods/types.rb

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args, &block) ⇒ Object



38
39
40
41
42
43
44
45
# File 'lib/eapi/methods/types.rb', line 38

def method_missing(method, *args, &block)
  resp = Types.check_asking_type method, self
  if resp.nil?
    super
  else
    resp
  end
end

Instance Method Details

#respond_to_missing?(method, include_all) ⇒ Boolean

Returns:

  • (Boolean)


30
31
32
33
34
35
36
# File 'lib/eapi/methods/types.rb', line 30

def respond_to_missing?(method, include_all)
  if Types.type_question_method(method).present?
    true
  else
    super
  end
end