> The names of the various Wheel tables are not known at design 
> time.

well..if this is the case, i don't see how you're really going to keep 
from some form of dynamic creation/metaprogramming/code generation and 
also keep the design clean...

maybe the option with the least dynamic change that I can think of is to 
keep a similar setup: one AbstractWheel class, and one ConcreteWheel 
class, but then have a method in the abstract class dynamically 
overwrite the table name of the ConcreteWheel Class based upon the fetch 
from the mapping table...of course, this means you have to reload the 
ConcreteWheel class every time....

of course, this raises the question for me, will all wheel tables have 
the exact same attributes and methods?  If not, then this method won't 
work...

As far as whether this has a standard name, what you're trying to do 
sounds like a problem that is solved by one of either a factory or a 
proxy, i'm not sure which...

-Gabe


-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to