title: Ruby: importing two modules/classes of the same name
body: <p>When my system requires two classes or modules of the same name, what can I do to specify which I mean?</p>
  
  <p>I'm using rails (new to it), and one of my models is named "Thread".  When I try to refer to the class "Thread" in thread_controller.rb, the system returns some other constant of the same name.</p>
  
  <pre><code>&lt;thread.rb&gt;
  class Thread &lt; ActiveRecord::Base
  
    def self.some_class_method
    end
  
  end
  
  &lt;thread_controller.rb&gt;
  class ThreadController &lt; ApplicationController
  
    def index
      require '../models/thread.rb'
      @threads = Thread.find :all
    end
  
  end
  </code></pre>
  
  <p>When I try Thread.find(), I get an error saying that Thread has no method named find.  When I access Thread.methods, I don't find my some_class_method method among them.</p>
  
  <p>Any help?  (And don't bother posting "just name your model something else."  It's not helpful to point out obvious compromises.)</p>