Edwin van der Elst wrote:
> If I use the taglib for business logic (modifying the db), I have to
> put my code in JSP's.
Modifying the db is mostly done by editwizards if I must make a site.
> I really don't want to get into that habit.
But I don't actually see a much of a problem in making edit or admin
pages in jsp only. I can imagine that one wants to split up the 'model'
from the 'view', but for simple sites even that is not worth the hassle,
because they contain normally only a few complicated queries. And even
then, I could imagine having 'model' JSP's which are included by 'view'
JSP's or so. Then everything is done in the same language, which would
seem pretty nice, easy and straight-forward to me...
Anyhow it is largely a matter of taste, I think, which is perhaps also
dependent on the number of people working on the project and on the
complexicity of the goal of the project. If your goal is relatively
simple, I think you must not make the means to reach it more complicated
then the goal itself...
> I also won't work for background processes (no JSP there)
That's true. But I think that's 10% of the functionality of a
site. At most!
>
> The exceptions are a nice addition in 1.8, didn't know about that yet.
> POJO's are still my prefered programming model (at least for business logic).
> It leads to more readable code and you can use typed collections:
> List<NewsItem> items;
> is better than:
> List<Node> item;
>
> List<Node> could be considered a typed collection, but is just a
> List<Object> in MMBase lingo.
Actually we have NodeList, which is a typed collection. We still are
stuck with 1.4 btw. I think only MMBase 1.9 will use java 1.5
features. (NodeList gets a bit weird then). Grantedly, node.getTitle()
is perhaps a bit nicer then node.getValue("title") because it checks
compile time whether title exists. But well, when developing in JSP, a
run-time check is made fast enough too :-) So, we could say that MMBase
bridge is much more like a scripting language.
Michiel
--
Michiel Meeuwissen mihxil'
Peperbus 111 MediaPark H'sum [] ()
+31 (0)35 6772979 nl_NL eo_XX en_US
_______________________________________________
Developers mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/developers