David J Rice

The blog of freelance Designer & Developer, David Rice.

07 Feb 2007

Convention over Configuration, it’s that simple. It makes my life a lot easier as a developer in so many ways. Sometimes when I’m thinking about programming problems I like to conceptualize them as conversations between me and the computer, both talking the same language. Why do I really love Ruby and Rails? because these languages let me have intelligent conversations with the computer, there’s no better way to explain this than to demonstrate.

Here is an example of an entirely fictitious conversation that happened this afternoon.

me: hey ruby
ruby: hey dave
me: hey ruby object, by the way you're a Message
ruby: oh really? cool!
me: so yeah, there are a couple of attributes i'd like you to have...
ruby: great!
me: right, I'm just writing a table structure for you
ruby: you want to store me in a database, okay.
ruby: so about those attributes, I thought you might want some methods to access them...
ruby: ...and some other stuff to check if i'm valid
me: okay okay, I'll ask you what methods you have later if I need to

Later that evening I had a similar conversation with another language.

me: hey java
java: hey dave
me: hey java object, by the way you're a Message
java: oh really? cool!
me: so yeah, there are a couple of attributes i'd like you to have...
java: great!
me: right, I'm just writing a table structure for you
java: good for you
me: i'd like to store you in database by the way
java: oh okay
me: well?
java: what?
me: what are you?
java: you said I was a message, with these attributes... and I have a database table or something
me: right.
me: well, you see that attribute I want you to store it here and the next one... 
java: ah right, okay gotcha

Have you had any intelligent conversations with your computer lately?

David Rice

If you need help with the Design, Build, Management, Hosting or Support of your project do get in touch, I'd love to hear from you!

Recently

Archive