Thursday, February 09, 2006

Naked Objects

I first heard about Naked Objects (the Naked Objects website is here) in a presentation at the SPA 2005 conference and have been intrigued since. I finally managed to find time to read the book (Naked Objects by Richard Pawson & Robert Matthews) and I can recommend it. Naked Objects brings a different approach to software architecture.

The book itself is different. Like Tom Peters Re-imagine! it is printed so it looks almost like a children’s book with lots of pictures and glossy pages. In particular I like the use of case studies - I think we in the software professions don’t make enough of case studies.

Both the Naked Objects philosophy and the Naked Objects framework are described. I’ve only skimmed the stuff on the framework, this takes the form of a tutorial section on the Java framework and seems to make extensive use of reflection so it might be difficult to port to some languages.

Still, the Naked Objects philosophy should be applicable in other languages. The approach won’t work for all domains: it won’t work where the application is of a highly scripted nature, where customers must use the software directly (e.g. a ATM/cash machine) or where there is a lot of data entry. Still, that leaves an awful lot of applications where it could work.

Naked Objects makes one very important assumption up front: it assumes the software user is not a dumb automaton but actually an engaged problem solver. This also implies you trust your staff (and if you don’t then why do you employ them?) and that they know the problem domain at least as well as the software - probably better. This allows developers to concentrate on functionality rather than interface or interaction design.

Basically, the idea is to expose objects directly. The objects have user meaningful methods with which the user interacts directly. So, if you want to book a Taxi in New York you put the New York object together with the Taxi object. In some ways it is taking Object Orientation to the extreme.

I’m not sure how this all fits with good software interaction design as described by Alan Cooper (The Inmates Are Running the Asylum) - I think in a domain where interaction design was key you probably won’t use this approach. However, where you can position your users as problem solvers the consistent interface pays off.

Once you start treating your users as problem solvers you assume that: they know best how to solve the problems, rather than try and think of everything that could happen and provide a way of dealing with it you provide the raw objects and let the users work out how to do something. And with that a large part of your work goes away, making you more productive; and because you are treating you users as intelligent beings they get more satisfaction from work and do a better job.

Overall I think the Naked Objects approach is very promising. It seems a particularly productive way of working. Everything I heard at SPA and in the book persuades me that this deserves more attention than it is getting.