MVC Framework for Swing?  
Author Message
Griffith Jones





PostPosted: 2006-6-13 22:18:00 Top

java-programmer, MVC Framework for Swing? Hello:

I'm looking for an MVC framework for Swing apps. I'm thinking of
something similar to Struts, but for desktop apps. I keep on writing
controllers for each Swing app I develope, and I can't believe there's not
a framework out there to expedite this.

Has anybody invented this yet?

Thanks




 
Thomas Weidenfeller





PostPosted: 2006-6-13 23:14:00 Top

java-programmer >> MVC Framework for Swing? Griffith Jones wrote:
> I'm looking for an MVC framework for Swing apps.

Swing, like many current GUI systems uses a variant of MVC. It typically
pays of to use that variant, instead of trying to beat Swing into
submission to get MVC.

> I keep on writing
> controllers for each Swing app I develope,

That's surprising, since much of what a Smalltalk-like controller is
supposed to do is handled internally by Swing.

Or maybe you are using a different definition of controller. There are
many, especially, because the Smalltalk people never bothered to
precisely define what their controller is (they just point to the
implementation in Smalltalk as the definition). Similar for MVC as such.
MVC is what is implemented in Smalltalk (of course there are different
variants in Smalltalk already ...).

> a framework out there to expedite this.

There are Swing application frameworks out there. Are you sure this is
really what you want? There are also Swing "beautification" libraries
and frameworks out there. Is this what you want?


/Thomas
--
The comp.lang.java.gui FAQ:
ftp://ftp.cs.uu.nl/pub/NEWS.ANSWERS/computer-lang/java/gui/faq
http://www.uni-giessen.de/faq/archiv/computer-lang.java.gui.faq/
 
Griffith Jones





PostPosted: 2006-6-14 1:43:00 Top

java-programmer >> MVC Framework for Swing? Thomas:

Thanks for the feedback.

I'm looking for Swing app frameworks, if you know of any ...

Griff Jones


"Thomas Weidenfeller" <email***@***.com> wrote in message
news:e6mknb$i9e$email***@***.com...
> Griffith Jones wrote:
>> I'm looking for an MVC framework for Swing apps.
>
> Swing, like many current GUI systems uses a variant of MVC. It typically
> pays of to use that variant, instead of trying to beat Swing into
> submission to get MVC.
>
>> I keep on writing controllers for each Swing app I develope,
>
> That's surprising, since much of what a Smalltalk-like controller is
> supposed to do is handled internally by Swing.
>
> Or maybe you are using a different definition of controller. There are
> many, especially, because the Smalltalk people never bothered to precisely
> define what their controller is (they just point to the implementation in
> Smalltalk as the definition). Similar for MVC as such. MVC is what is
> implemented in Smalltalk (of course there are different variants in
> Smalltalk already ...).
>
>> a framework out there to expedite this.
>
> There are Swing application frameworks out there. Are you sure this is
> really what you want? There are also Swing "beautification" libraries and
> frameworks out there. Is this what you want?
>
>
> /Thomas
> --
> The comp.lang.java.gui FAQ:
> ftp://ftp.cs.uu.nl/pub/NEWS.ANSWERS/computer-lang/java/gui/faq
> http://www.uni-giessen.de/faq/archiv/computer-lang.java.gui.faq/


 
 
Karsten Lentzsch





PostPosted: 2006-6-14 3:08:00 Top

java-programmer >> MVC Framework for Swing? Griffith Jones wrote:

> I'm looking for an MVC framework for Swing apps. I'm thinking of
> something similar to Struts, but for desktop apps. I keep on writing
> controllers for each Swing app I develope, and I can't believe there's not
> a framework out there to expedite this.

I suggest you check out the MVP and "Presentation Model"
patterns. Just google "Organizing Presentation Logic",
and you'll get a reference to a narrative by Martin Fowler
where he motivates MVP and Presentation Model.

I've found that a good understanding of these patterns
helps every project, where in contrast other techniques
like automatic databinding can increase or decrease your
productivity.

Once you're familiar with these patterns, you may choose
a helper library or framework that follows one of these
approaches.

I provide presentation about desktop patterns and
data binding at http://www.jgoodies.com/articles/
and a free open source helper library for working
with the Presentation Model pattern in Swing:
the JGoodies Binding. But as said in the slides,
automatic data binding is a wild horse that may
be difficult to ride on.

-Karsten
 
 
Griffith Jones





PostPosted: 2006-6-14 4:19:00 Top

java-programmer >> MVC Framework for Swing? Much thanks for the references, Karsten. Ditto the excellent tool library
...

Griff Jones


"Karsten Lentzsch" <email***@***.com> wrote in message
news:e6n2f7$5d4$01$email***@***.com...
> Griffith Jones wrote:
>
>> I'm looking for an MVC framework for Swing apps. I'm thinking of
>> something similar to Struts, but for desktop apps. I keep on writing
>> controllers for each Swing app I develope, and I can't believe there's
>> not a framework out there to expedite this.
>
> I suggest you check out the MVP and "Presentation Model"
> patterns. Just google "Organizing Presentation Logic",
> and you'll get a reference to a narrative by Martin Fowler
> where he motivates MVP and Presentation Model.
>
> I've found that a good understanding of these patterns
> helps every project, where in contrast other techniques
> like automatic databinding can increase or decrease your
> productivity.
>
> Once you're familiar with these patterns, you may choose
> a helper library or framework that follows one of these
> approaches.
>
> I provide presentation about desktop patterns and
> data binding at http://www.jgoodies.com/articles/
> and a free open source helper library for working
> with the Presentation Model pattern in Swing:
> the JGoodies Binding. But as said in the slides,
> automatic data binding is a wild horse that may
> be difficult to ride on.
>
> -Karsten


 
 
Thomas Weidenfeller





PostPosted: 2006-6-14 15:49:00 Top

java-programmer >> MVC Framework for Swing? Griffith Jones wrote:
> I'm looking for Swing app frameworks, if you know of any ...

I haven't followed java app framework development closely. So some of
the stuff in the list below no longer exist or is not suited. Anyhow,
you might want to have a look at JLense, Kanabos, Pustefix, Merlin,
Jaffa, Pulpitum, JGoodies, JUICe, or Atris Framework. Oh, and both
Netbeans and Eclipse (the IDEs) do have some RCP (rich client platform).
The NetBeans Rich Client Platform and the Eclipse Rich Client Platform
respectively.

Sun is also going to standardize an app framework in JSR 296, related to
http://wiki.java.net/bin/view/Javadesktop/SwingLabs. But that will take
some time, and it will be a committee compromise.

There is also stuff like SwiXML or XUI for the XML-everywhere fanboys.

/Thomas
--
The comp.lang.java.gui FAQ:
ftp://ftp.cs.uu.nl/pub/NEWS.ANSWERS/computer-lang/java/gui/faq
http://www.uni-giessen.de/faq/archiv/computer-lang.java.gui.faq/
 
 
Griffith Jones





PostPosted: 2006-6-14 23:08:00 Top

java-programmer >> MVC Framework for Swing? Thanks Thomas, that's a big help ...

Griff Jones

"Thomas Weidenfeller" <email***@***.com> wrote in message
news:e6of12$g2s$email***@***.com...
> Griffith Jones wrote:
>> I'm looking for Swing app frameworks, if you know of any ...
>
> I haven't followed java app framework development closely. So some of the
> stuff in the list below no longer exist or is not suited. Anyhow, you
> might want to have a look at JLense, Kanabos, Pustefix, Merlin, Jaffa,
> Pulpitum, JGoodies, JUICe, or Atris Framework. Oh, and both Netbeans and
> Eclipse (the IDEs) do have some RCP (rich client platform). The NetBeans
> Rich Client Platform and the Eclipse Rich Client Platform respectively.
>
> Sun is also going to standardize an app framework in JSR 296, related to
> http://wiki.java.net/bin/view/Javadesktop/SwingLabs. But that will take
> some time, and it will be a committee compromise.
>
> There is also stuff like SwiXML or XUI for the XML-everywhere fanboys.
>
> /Thomas
> --
> The comp.lang.java.gui FAQ:
> ftp://ftp.cs.uu.nl/pub/NEWS.ANSWERS/computer-lang/java/gui/faq
> http://www.uni-giessen.de/faq/archiv/computer-lang.java.gui.faq/