[aida] Comment on the tutorial
petton.nicolas at gmail.com
Mon Sep 22 21:35:13 CEST 2008
Le lundi 22 septembre 2008 à 21:23 +0200, Stephen Davies a écrit :
> 2008/9/22 nico <petton.nicolas at gmail.com>
> In AIDA/Web, domain objects have urls. In fact, the idea
> behing this is
> that each object has its own url. So, we create links between
> never between applications.
> So, yes, it's :
> "e addLinkTo: self observee..."
> So the tutorial should be corrected.
> > (It does seem wrong to me that the view for adding an
> address is in the AddressBook model, but I leave that to
> another post).
> No! View methods are always in the applications. The model
> doesn't deal
> with view and action methods.
> Sorry - I made a mistake in my comment and so my objection wasn't
> The tutorial tells you to create a viewAdd method to the
> ADemoAddressBookApp class. I understand that it is on the "App" class
> - that's the "View" in my understanding of MVC.
> But the viewAdd method has to know all about the insides of an
> "ADemoAddress". So its in the wrong place. The code that knows
> what's inside an ADemoAddress should ideally be in the ADemoAddress
> class, not so? Or, maybe the ADemoAddressApp.
Yes, you're right. But for a first tutuorial, I guess it was simpler to
do it this way.
> Actually, the same objection stands for the viewMain method in
> ADemoAddressBookApp, which knows the names of the "columns" (instance
> variables) of the ADemoAddress.
> Am I picking nits?
Well, it's just a tutorial, but for real aida applications it's better
to write views (#viewAdd in this case) in the right place :)
Ma clé PGP est disponible ici :
-------------- section suivante --------------
Une pi�ce jointe non texte a �t� nettoy�e...
Nom: non disponible
Taille: 189 octets
Desc: Ceci est une partie de message
More information about the Aida