Class: Object

Inherits:
BasicObject
Defined in:
lib/import_everything/ext.rb,
lib/import_everything/ext.rb,
lib/import_everything/ext.rb

Instance Method Summary collapse

Instance Method Details

#first_responding(*methods) ⇒ Object



86
87
88
89
90
91
# File 'lib/import_everything/ext.rb', line 86

def first_responding(*methods)
  methods.flatten.each { |x| return send(x) if respond_to?(x) }
  #raise "none respond"
  #raise local_methods.inspect
  nil
end

#fixed_objObject



63
64
65
# File 'lib/import_everything/ext.rb', line 63

def fixed_obj
  self
end

#local_methodsObject



2
3
4
5
# File 'lib/import_everything/ext.rb', line 2

def local_methods
  res = methods - 7.methods - ''.methods - Object.new.methods
  res.sort
end