M
Martin Gregorie
Yes, that's looking steadily better the more I think about it. Instead ofHmm. The more i think about it, the more i think a single class might be
a good idea. But it would involve putting both search- and
update-specific code in the model. Which isn't necessarily so bad - a
well-rounded class supporting both read and write operations is a fairly
common thing to find in a domain object layer. It really depends how
complex the code you want to put in the model is.
a single CRUD GUI program I've got two, the idea being that one can be
given to anybody because it can't damage the database (no insert/update/
delete capability at all while the other, which can do these things, is
intended only for suitable authorised users: most data is bulk loaded and
the update GUI is only there for removing to odd piece of junk and
tidying up. IOW, a single model for these GUIs isn't a bad idea.
That fits in this case. The bulk loader is near as dammit loading a data"Of course"! There's no law against CLI programs having object models!
Although if they exist purely to move data in and out of databases, a
model may be an unnecessary complication.
warehouse. Think of it as throwing each item of input into the fact table
and adding a few dimensions to speed up searches. The second CLI is a
bulk unloader which is essentially just dumping the fact table, so
neither program has any need of a model.
As I said elsewhere, I'll merge the two models and do the same with theRight. Get your backspace key out.
corresponding JDBC layer.
I have almost no OO background and have no idea who the currentlyAre you serious, or is my irony detector broken?
recognised OO design gurus are. I've heard of Booch, but have never seen
him mentioned here. Hence the question.
Thanks. Thats exactly what I wanted to know.These are the two most important books about the craft of
objected-oriented software ever written:
BTW, and to show where I'm coming from, apart from K&R, I think the best
non-OO programming books in my library are:
1) Software Tools in Pascal (Kernighan & Plauger)
2) Algorithms (Sedgewick)
3) The Practise of Programming (Kernighan & Pike)
4) Algorithms + Data Structures = Programs (Wirth)
5) An Introduction to Database Systems (Date)
and, no, I don't have a copy of Knuth. So far Sedgewick and Wirth have
filled that need.
(1) is still about the best book I know about designing reusability into
code modules while (3) should be read by every programming neophyte, OO
or non-OO for its advice in code readability and designing testability
into your code. As for (5), Date is great. He manages to combine an
understanding of DB principles with good design and implementation
guidance.