Ignore changes in the amount of whitespace
Differences between version dated 2004-12-03 09:58:09 and 2005-02-02 05:16:17
(spanning 2 versions)
Deletions are marked like this.
Additions are marked like this.
= Lesson Two: Domain Models and Data Retrieval =
Now its time to go a tiny step beyond the triviality of the "Hello,
Now it's time to go a tiny step beyond the triviality of the "Hello,
world!" example. In this chapter I'll expand the example to handle
saying hello to an arbitrary variety of things. Since we want to
be flexible. we'll get the greeting message for each thing from a
to other kinds of objects. In PEAK-speak, the objects are called
"Elements", and the relationships are called "Features". Features are
implemented as object attributes, using custom descriptors.
See the GraphvizTutorial for more info on Domain Models.
To facilitate grabbing data from our database, we'll define a simple
Element class, in a `model.py` file in our helloworld package: {{{