The Source for Java Technology Collaboration
User: Password:



Chet Haase's Blog

October 2007 Archives


Male Pattern Boldness

Posted by chet on October 25, 2007 at 08:03 AM | Permalink | Comments (5)

Longtime readers of my blog will know that I'm a huge fan of Design Patterns. Patterns wrap complex architectures with simplistic descriptions. They create wonderful buzzwords that we can use instead of resorting to actual human language descriptions. And they help enforce that feeling that we're all a part of an elite clique shunned by society not by their choice, but by ours.

So it is with much happiness and joy (refer to the Joyous Configuration pattern for more background on this emotion) that I hereby announce more patterns to help the software community in the tedious and underappreciated lives that we lead.

Refactory

The Refactory pattern, a spin-off of the earlier Factory pattern, is useful for engineering teams that enjoy the infinite redesign cycle of software. While the code may work perfectly well in some configuration, chances are great that the entire code base can be completely refactored to have the same functionality, but with different class hierarchies, indenting styles, and naming conventions. This pattern provides for such standard refactoring methods as arbitraryRename(), codeRestyler(), classHierarchyFlattener(), and classHierarchyExpander(). This single pattern is often credited with being the cornerstone of our entire industry.

Delicate

The Delicate pattern, like the traditional Delegate pattern, is signified by its extreme use of indirection and object layering, where a successful implementation will be comprised of so many layers of API and object wrappers that the final result is apt to break easily and nondeterministically. As Chris Campbell pointed out to me, the Delicate pattern is a critical part of the trendy Fragile Programming methodology.

Obliterator

The Obliterator pattern is a combination of the Iterator pattern, which is useful for walking through a list of objects, and deletion functionality. When applied to any list of objects, it automatically walks the list and deletes all members, then removes the list, the calling function, and the application itself. Variations of the pattern have been known to also destroy the operating system, the computers running the system, the networks on which the pattern is deployed, and the universe in which the pattern exists. Use with care, or at least ask your users to test it for you before declaring the product final.

Veneer

The Veneer pattern is a thin, attractive wrapper on top of a rat's nest of spaghetti code. The pattern is similar to its forerunner, the Façade pattern, except that it avoids the use of special internationalized letters that make correct spelling difficult for English programmers.

Disfunctional

Contrary to the related Functional Design pattern, the Disfunctional pattern requires every component of a system to know about and perform every possible operation. Variants of the pattern exist, such as the Gossip and Nosey Parker patterns.

Lethargic Initialization

Like the Lazy Initialization pattern, the Lethargic Initialization pattern delays creation and calculation until such time as it is needed. However, the Lethargic pattern adds the additional requirement that operations be carried out slowly, if at all, and may not actually complete when the information is needed by the system. This approach has distinct advantages over the Lazy pattern. Systems using the Lethargic approach can never suffer the performance hit that is possible with the Lazy pattern, because at no time is the system actually doing much, if any, work.

Single

Like the Singleton pattern, the Single represents objects of which there is only one instance in the system. However, the Single pattern has the important distinction that its objects are constantly on the search for other objects to combine with, in a desperate attempt to avoid being stuck on their own. A Single object will print any line, tell any recursion tail, or go into any foo bar as it tries to pair off with other Singles.

Cunning Plan

Like the earlier Strategy pattern, the Cunning Plan pattern cleverly selects the implementation of an algorithm on the fly. However, this more radical approach automatically selects the most devious and subversive methodology, designed to undermine the entire system from within.

It's clear that there are many more patterns that we can invent if we just set our minds to the task and find appropriately obscure words with which to name them. But hopefully the selection above will invigorate the community to begin implementing brave new architectures based on proven, robust buzzwords.



Move It!

Posted by chet on October 23, 2007 at 07:41 AM | Permalink | Comments (7)

Introducing Animated Transitions, a new library for the easy creation of animated segues between application states.

It's been a long slog, from initial demos of the technology in a session on "Advanced 2D" at JavaOne 2005, to use of an early version of the library in the Aerith application, to finishing off the library and creating more demos exercising it for the book Filthy Rich Clients, to getting legal approval for pushing the actual source code (an exercise over the last several months that was not unlike slamming the refrigerator door on my head, over and over. Every day.).

But it's finally done, and the long-awaited day is finally here:

The Animated Transitions library is hereby released

The project is available on java.net at http://animatedtransitions.dev.java.net with a BSD license.

The library is fully described in Chapter 18 of Filthy Rich Clients. That chapter includes a complete description of the library's API, detailed explanations of two sample applications that use the library, and some nitty-gritty details on how the library internals work.

But because there are probably a couple of people left on the planet that do not yet have a copy of the book (no idea how this happened. Maybe it's because we have been so quiet about it. We should really talk more about it), and because I'm such a nice guy and all, I wrote up a short tutorial on the basics of using the library, along with a new demo that shows the basics in action. You can find that tutorial in the java.net article, "Create Moving Experiences with Animated Transitions".

In fact, here's a web-started version of the demo so that you can see it in action. Click on the handy image below and run it. Click on the More/Less buttons to see what it's all about. Note: There are some artifacts reported on the Mac, perhaps related to the way they treat layout and the panels that contain the buttons.

Transition1-2.png

Play around with it. Check out the article and the accompanying demo. Check out the demos on the book's website. Write your own demos. Or, even better, use the library in your actual applications. Make those applications more dynamic and help your users actually understand the interfaces they're beset with.

Go on: Move it!



Filthy Download

Posted by chet on October 16, 2007 at 08:35 AM | Permalink | Comments (3)

The publisher just informed us that they've made a downloadable DRM-encrypted PDF version of Filthy Rich Clients available here. I know that some folks have been asking about this for a while, so it seemed worth another shamelessly self-promoting, yet thankfully brief, blog entry to call attention to it.



Early Access Granted: Java SE 6 Update N

Posted by chet on October 01, 2007 at 11:42 AM | Permalink | Comments (19)

JavaSE6UpdateNPicSm.png

It's here (almost), it's ready (for testing), and it's got a cooler name than ever before.... Java SE 6 Update N (formerly known as the Consumer JRE) is available for early access.

Remember when I talked about an upcoming Java SE 6 release that should address many of the outstanding issues for Java on the client? We used to call it "The Consumer JRE", but then we decided that "Java SE 6 Update N" was a much cooler name. Rolls right off the tongue. More SExy, like. Besides, as my buddy Willy Shakespeare was fond of saying:

What's in a name? that which we call Java SE6 Update N
By any other name would smell as sweet

(I don't know what's up with the "smell" thing. I think it's poetic license.) Whatever the release is called, many of the features in the release are ready for testing. Head on over to the download page and give it a whirl.

Some of the important features in this release (which, by the way, should make for a better Java FX experience when it's released), include:

  • Java Quickstarter : Faster coldstart for Java applications and applets
  • Deployment Toolkit: Easier detection of a user's Java version from a web page. (Note that the current Testing page is light on details for this feature - we plan to update this item in the next couple of days with specific information about testing this).
  • Graphics Performance : Acceleration through Direct3D on Windows for Java 2D, enabled by default
  • Nimbus: A new Swing cross-platform look & feel that's much more modern and cool than Metal. Scott Violet was saying that some look & feels were so cool you wanted to lick them. Along those lines, I'd claim that Nimbus is our first Swing lick & feel.

Note that some items planned for the final release are not there yet (we're still working on them). In particular, Java Kernel is still baking internally before we unleash it. So you'll have to check back in a few weeks if you want to hammer on that one.

More information about what is and is not available for testing in this release so far is on the Testing Guidelines page.

Please try it out and send us feedback on it. In particular, please send feedback through the handy Feedback forum on the download page. Much as I enjoy the comments to my blog, I would rather have important release feedback go to the folks that are directly working on the issues to make sure that your input gets heard.





Powered by
Movable Type 3.01D
 Feed java.net RSS Feeds