Sha256: 8e79b0590bd5876d4d6e3db6311c9b70df076a091963fa8c4515a54cb20c2b97
Contents?: true
Size: 545 Bytes
Versions: 4
Compression:
Stored size: 545 Bytes
Contents
module VORuby module Utilities def self.save_to(file, in_string) out_file = File.new(file, 'w+') out_file.puts(in_string) return out_file end def self.subclass_names(klass, preserve_ns=true) subclasses = [] ObjectSpace.each_object(Module){ |c| if c.ancestors.include?(klass) if !preserve_ns subclasses << c.name.split('::')[-1] else subclasses << c.name end end } return subclasses end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
voruby-1.1 | lib/voruby/util.rb |
voruby-1.0.1 | lib/voruby/util.rb |
voruby-1.0.2 | lib/voruby/util.rb |
voruby-1.1.1 | lib/voruby/util.rb |