**DONOTDELETE**
(Unregistered)
07/30/03 01:29 AM
Not usually applicable

While the pattern does reduce object creation it is not always as applicable as this article implies. For instance the line drawing example has a huge issue. It can not repaint itself after a blur. The data to paint it is not stored anywhere. The heavy weight version could be readily modified to be re-drawable.

The swing tree node example that displayed the file system does work well, because the state is stored in the file system. If the re-fetch of the data was more expensive (like database or web service) then it would be necessary to maintain sufficient state to repaint.

The article is concise though!



Contact us JavaWorld

Powered by UBB.threads™ 6.5.5

Featured White Papers


RESEARCH CENTERS: Java Standard Edition | Java Enterprise Edition | Java Micro Edition | Development Tools
About Us | Advertise | Contact Us | Terms of Service/Privacy
Copyright, 2006-2008 Network World, Inc. All rights reserved.