> Personal experience is valuable, but you can't always know that this > design will be just like the last one.
I don't think about it as a matter of design but just common sense in most cases. I'll explain later. > > I'd rather spend 30 or 60 extra minutes > > giving a universal solution to a problem or generating related > > additional functionality that I might see a use for (but not needed > > right now) than having to go back and spend days reworking something > > because of those 'saved' 30 or 60 minutes. > > That's a poor trade-off. I know it looks good, but it really isn't. > What you're doing is wasting 30-60 minutes for something that you don't > need now and may never need. Just a silly example: At a place I used to work I was using a much less flexible language than Ruby. This language didn't have by far the capabilities to calculate dates or handle strings that Ruby has or the flexibility to run SQL statements that Rails provides. So during my work there I was tired of hard coding SQL statements all over the place, escaping countless quotes, etc. The code statements were ugly looking and difficult to read. I didn't really 'need' a tool or a system to make the whole thing more flexible, nobody asked for it!, but I got to it and created a system to handle the SQL statements in a much more flexible manner and while I was at it I built additional string and date handling routines that I didn't need at the time. They were initially conceived only to solve the SQL string problems. After 1/2 a day or so of work I had a good additional set of functions that could handle not only the SQL string problems I had but also much more generic string functionality that was natively missing in the language. Think something like 'squeeze'. Did I need all that? No. Was it nice to work with it after I was done? You betcha! And the funny thing is that after I created all that the other developers started using the string and date functions I had created. So what did the 1/2 day bought me? Personally, not much, maybe satisfaction would be most of it. To the company it meant countless of productivity hours gained, only because I "over- engineered" something I didn't even need to do. -- 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 rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.