Swing JavaBuilder 1.1 : Declarative UIs With Maximum Productivity
“Just started on using the Swing JavaBuilder and i must say i like it. Just replaced 170 rules of Java code with only 13 lines YAML”
Comment posted the JavaBuilders forum
Published at DZone with permission of its author, Jacek Furmankiewicz.Comment posted the JavaBuilders forum
Swing JavaBuilder 1.1 is out:
http://javabuilders.googlecode.com/files/javabuilder-swing-1.1.0-dist.zip
Please read our PDF book to get started.
Also, you can view our original JavaLobby article, although it refers to the older 0.3 version.
New in 1.1:
* switch to SnakeYaml for YAML parsing (which results in much more readable error messages)
* changed default file extension to .yml instead of .yaml
* misc bug fixes
Website: http://code.google.com/p/javabuilders/
Location:
Montreal, Canada
| Attachment | Size |
|---|---|
| SwingJavaBuilder-1.1.pdf | 389.46 KB |
(1 vote)
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)





Comments
Fred Swartz replied on Wed, 2010/12/22 - 11:41am
Undergraduate Java programming students often hit the GUI wall, where the difficulty of developing an interface discourages them enormously. It's sadly too late to move students to declarative interfaces, but something like SwingJavaBuilder would have allowed them to move into GUIs with relative ease.
I've tried other declarative GUI packages before, but thought SwingJavaBuilder to be better. One that I'd consider more if I had the time is Apache Pivot but the XML looked annoyingly verbose compared to the compact YAML notation at first glance.
Jacek Furmankiewicz deserves some kind of award for this work and his rapid response to any questions.
Cons: You have to learn the compact YAML notation (easy) and how to use MigLayout (far easier than the Java layout mess). Errors are caught at runtime instead of compile time, and the diagnostic messages are not always as quite as helpful as one would wish.
It's hard to imagine that someone wouldn't prefer this after using on just one project.
Jacek Furmankiewicz replied on Wed, 2010/12/22 - 1:38pm
in response to:
Fred Swartz
Greg Matoga replied on Thu, 2010/12/23 - 2:10am
Jacek Furmankiewicz replied on Thu, 2010/12/23 - 7:01am
in response to:
Greg Matoga
Swing JB just builds your GUI and wires your listeners to Java methods. What you do in them is 100% up to you.
So, no it does not have any built-in REST support, but that's not its not goal. It's not a web framework nor a rich client platform. It's a library meant to dramatically reduce the LOC (lines of code) required to construct a GUI. That's where it ends.
In a Ruby on Rails context, think of it as Swing's equivalent of Haml :-)Jacek Kruszelnicki replied on Thu, 2010/12/23 - 1:20pm
Jacek Furmankiewicz replied on Thu, 2010/12/23 - 1:33pm
in response to:
Jacek Kruszelnicki
I have postponed it indefinitely.
With Oracle's disappointing leadership of Java (in particular its hostile attitude towards open source and the Google lawsuit), I am reducing my involvement in new open source Java projects. I am however 100% committed to the continued development and maintenance of Swing JavaBuilder.. I just started working on the new dev 1.2 branch, which will focus on more advanced GlazedLists integration.
Kondwani Mkandawire replied on Wed, 2011/02/23 - 5:58am
Call me simple minded but I fail to see the benefit of learning a new Syntax in Yaml combined with Java to create a Java App. So now the developer has to have 2 mind sets? The reason Wicket is so popular (and awesome) is that it eliminates the amount of stuff you have to know. i.e. no Java Script, no Struts config files - hence you eliminate the XML mind set - after setting up web.xml you are in pure Java Mode (HTML is in a separate thought domain).
If what we are achieving after wacking together the extra Yaml files is databinding wouldn't it be easier to learn Spring Rich Client? Or write your own databinder via reflection?
Sorry this might appear extremely simple to those who are in a position to appreciate Yaml - maybe I should do a little research on it - but I'm just trying to understand the mind set here.
Jacek Furmankiewicz replied on Tue, 2011/03/15 - 8:00pm
in response to:
Kondwani Mkandawire
The other 95% is are terse creation of objects, complex layout management via a DSL on top of MigLayout, built-in validators, support for running background tasks via SwingWorker, GlazedLists integration for table-based panels, etc.
One of our early adopters rewrote their whole banking platform from .Net Windows Forms to Swing JavaBuilder. They saw the long term value of increased productivity and *easy* maintenance.
Bikes Direct replied on Thu, 2011/08/11 - 12:26pm
Jennifer Frugalidad replied on Fri, 2011/08/19 - 11:00pm