method
add_class_or_module

add_class_or_module(collection, class_type, name, superclass=nil)
public
Hide source
# File lib/rdoc/code_objects.rb, line 375 def add_class_or_module(collection, class_type, name, superclass=nil) cls = collection[name] if cls then cls.superclass = superclass unless cls.module? puts "Reusing class/module #{name}" if $DEBUG_RDOC else cls = class_type.new(name, superclass) # collection[name] = cls if @document_self && !@done_documenting collection[name] = cls if !@done_documenting cls.parent = self cls.section = @current_section end cls end