From: "J. Ryan Sobol" Date: 2005-12-25T23:46:47+09:00 Subject: Re: Where is the attribute definition of Category class? On Dec 25, 2005, at 8:12 AM, sadys.humblebee@gmail.com wrote: > I know, i know,:-) > ActiveRecord that by implementing the Object#method_missing method > which will be called whevever trying to access a attribute not defined > yet. > Is that right? > But in a big team-developing software, how can I enforce the precise > reference of my classes' attributes by other developers, not refering > to non-exist attribute? of course this will raise "column not found" > exception at runtime, but can we prevent it from the very beginning. > > Obviously every organization's coding practices differ, but I'll bet that your colleagues would rather have good documentation for your classes rather than having your classes perfectly insulated in their own little world, regardless if your using Rails or not. Also, the Rails philosophy is more about using conventions over configuration. The way Active Record handles table attributes is a convention that, once internalized, allows significant speed up in development time. If everyone in your organization understands this convention, there's no need to go against that grain. Again, I encourage you to talk directly with Rails community as they're probably better suited to answer these sorts of questions. ~ ryan ~