13.07.2015 Views

Java™ Application Development on Linux - Dator

Java™ Application Development on Linux - Dator

Java™ Application Development on Linux - Dator

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

17.2 The IBM SWT Toolkit37917.2.2 Duplicated Effort. Why Cover It?The next logical questi<strong>on</strong> is, “If you think SWT is unnecessary with Swing alreadythere, why cover it in your book?” Also a sensible questi<strong>on</strong>. The answeris that there is very little published literature <strong>on</strong> this library (a notable excepti<strong>on</strong>being Chapter 10 of The Java Developer’s Guide to Eclipse by Shaver et al., fromAddis<strong>on</strong>-Wesley). Also, SWT provides the <strong>on</strong>ly fully functi<strong>on</strong>al GUI librarythat will work with the GNU Compiler for Java. As such, it is a major requiredcomp<strong>on</strong>ent if you wish to write native compiled GUI applicati<strong>on</strong>s <strong>on</strong> <strong>Linux</strong>systems.Of course, there is another reas<strong>on</strong>. Any<strong>on</strong>e heavily into <strong>Linux</strong> is well awareof the political and philosophical debate about Free Software and Open Source.If the core values of Free Software are critical for you, you should be aware thatthe IBM Comm<strong>on</strong> Public License 5 under which Eclipse (and thus SWT) arepublished is a Free Software license. You get the source code, you may use itin your own products, and it imposes obligati<strong>on</strong>s similar to the GNU GPL, 6but goes even further by requiring you to grant royalty-free licenses for anypatents you hold in derivative works.So you might choose SWT (or not) for political or philosophical reas<strong>on</strong>s.Both authors still suggest Swing first because it is the official Java GUI library.When an employer wants to know if you can write a Java GUI applicati<strong>on</strong>, heor she almost certainly means a Swing applicati<strong>on</strong>. Philosophy is great, but itmay not put the food <strong>on</strong> your table. You need to know that Swing is not FreeSoftware (and neither is either of the major Java SDKs), and SWT is FreeSoftware, but it is up to you to decide what best serves your interests. 75. http://www.eclipse.org/legal/cpl-v10.html6. http://www.gnu.org/licenses/gpl.html7. A lot of people couldn’t care less about the Free versus n<strong>on</strong>-Free issue, but I must say thatmany of my most interesting workplace discussi<strong>on</strong>s have arisen from this issue. It is the firstissue in my career that has had programmers talking about the balance between their pers<strong>on</strong>alinterests, their employers’ interests, and the public interest. Wherever you stand philosophically,I think it is good that programmers are thinking about the c<strong>on</strong>sequences of their work at allof these levels. I wish there were more pressure at all levels of business to c<strong>on</strong>sider and balanceall of these interests.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!