Sha256: 966dd705bc9d9b30ccdb70ce3a3863f75a1b7d2cb69d26bcf8747022216f9adc
Contents?: true
Size: 373 Bytes
Versions: 9
Compression:
Stored size: 373 Bytes
Contents
module ObjectSpace class << self # Returns all the classes in the object space. def classes klasses = [] ObjectSpace.each_object(Class) { |o| klasses << o } klasses end def modules modules = [] ObjectSpace.each_object(Module) { |o| modules << o } modules end end end unless ObjectSpace.respond_to?(:classes)
Version data entries
9 entries across 9 versions & 1 rubygems