Hello all,

I'm having a problem with some dynamic classes that I'm trying to use
in my development environment.

My app is creating some dynamic classes that descend from
ActiveRecord::Base.  Now this part works fine, except that they only
exist for the life of one request in my development environment and
then they no longer exist.  I'm calling a method from my
environment.rb to to do the initial class creation.

My current approach to recreating these classes is to use
const_missing if the classes aren't found, but I'm not having very
much success with this approach.  I'm not sure this is even a safe
approach to solving my problem, so I was wondering if somebody (with
more in depth knowledge of how classes are reloaded) can give me a few
pointers on things I should be looking for, trying.

I can post some code if needed, but maybe there are some general
guidelines I should be following to begin with.

Thanks,
Andrew
_______________________________________________
Rails-core mailing list
Rails-core@lists.rubyonrails.org
http://lists.rubyonrails.org/mailman/listinfo/rails-core

Reply via email to