From: Patrick Hurley Date: 2005-03-26T04:03:48+09:00 Subject: Re: loading "plugins" Oops I realized you might want to "discover" what classes you loaded so something like this might be closer: before_classes = [] ObjectSpace.each_object(Class) { |obj| before_classes << obj } base= "." Dir.glob("#{base}/*.rb").each { |plugin| require plugin } new_classes = [] ObjectSpace.each_object(Class) { |obj| new_classes << obj unless before_classes.include?(obj) } And then you can further check the loaded classes (in new_classes array) by using the respond_to? method (check to see if it is a Duck :-) Patrick