Method: FlatMap::OpenMapper::Mounting#respond_to_missing?

Defined in:
lib/flat_map/open_mapper/mounting.rb

#respond_to_missing?(name, include_private = false) ⇒ Boolean

Look for methods that might be dynamically defined and define them for lookup.

Returns:

  • (Boolean)


169
170
171
172
173
174
175
176
177
178
179
# File 'lib/flat_map/open_mapper/mounting.rb', line 169

def respond_to_missing?(name, include_private = false)
  # Added magically by Ruby 1.9.3
  if name == :to_ary || name == :empty?
    false
  else
    return true if mapping(name).present?

    mounting = all_mountings.find{ |mount| mount.respond_to?(name) }
    return false if mounting.nil?
  end
end