Sha256: ee75320943312b6203b7cf3e1e0199c73ddc5cb3dceaa9a172cd70a349a82bee
Contents?: true
Size: 770 Bytes
Versions: 5
Compression:
Stored size: 770 Bytes
Contents
include T('default/module') def init super sections.place(:subclasses).before(:children) sections.delete(:children) sections.place([:constructor_details, [T('method_details')]]).before(:methodmissing) end def constructor_details ctors = object.meths(:inherited => true, :included => true) return unless @ctor = ctors.find {|o| o.name == :initialize } erb(:constructor_details) end def subclasses if !defined? @@subclasses @@subclasses = {} list = run_verifier Registry.all(:class) list.each do |o| (@@subclasses[o.superclass] ||= []) << o if o.superclass end end @subclasses = @@subclasses[object] return if @subclasses.nil? || @subclasses.empty? @subclasses = @subclasses.sort_by {|o| o.path } erb(:subclasses) end
Version data entries
5 entries across 5 versions & 1 rubygems