Anyway, I just found out that I can't get the thing done I was working on using a attribute modifier. So, I have to make a whole custom implementation anyway. The argument for DataTextField still stands...

What I am missing in the Javalobby discussion is component orientation. When you develop high level reusable components, you'd generally want your users to have to know the least possible about how the implementation works. In this respect (and I am looking at this with the goal of creating high level components for contrib), I want to be able to tell a user, 'hey, just use that component, and you have a special text field that will color yellow when the field is required and color red on a validation error'. Now, internally, that component actually works with composition. But the high level component makes it even easier for the user as the composition is hidden for him. From an OO zealot's point of view, there's a lot to say for using composition rather than inheritance. For that reason, I wouldn't want this kind of structures too much in the core project. However, the contrib lib is another thing. It is my goal to have a set of components in them that can be used immediately without having to figure out how the internal composition works. For users wanting to go a step further than that, I'd want the users to be able to look at how the composition is done, and have them be able to do this themselves (probably in an altered way). That's why I did not make the 'required' atribute modifier and the 'validation' (error) attribute modifier private classes.

Eelco


Eelco Hillenius wrote:

Regardless of that discussion, most people will be glad that JFrame (or JTextField!) are not final. You don't have to extend them, but if you feel in your case it would be better to do so, you can. Because they're non-final.

Eelco

Martijn Dashorst wrote:

A nice discussion on JavaLobby concerning just this subject.

http://www.javalobby.com/forums/thread.jspa?threadID=16487&messageID=91822159&tstart=0



Martijn




-------------------------------------------------------
This SF.Net email is sponsored by: IntelliVIEW -- Interactive Reporting
Tool for open source databases. Create drag-&-drop reports. Save time
by over 75%! Publish reports on the web. Export to DOC, XLS, RTF, etc.
Download a FREE copy at http://www.intelliview.com/go/osdn_nl
_______________________________________________
Wicket-develop mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-develop

Reply via email to