By bloid
via onyxbits.de
Published: Nov 17 2008 / 04:52
Three days ago, I posted a design pattern for menubars. While the article was mainly about code clarity and the clumsiness of inner classes, it also contained some remarks concerning performance and naturally this puts me in a put up or shut up situation, even though a performance discussion was not really my intention.
Comments
MattRussell replied ago:
Kudos for running the numbers. (An extra observation: Pack200 would mean the difference between the compressed code size is about 4.2k vs 1.5k.) Personally, I'd conclude that the performance difference is negligible for anywhere you'd be running Swing, and the question is really one of which implementation is clearer. What would ultimately be the cleanest solution to wiring up behaviour to menus, that is, adding full closure support in the language, would almost certainly be implemented under the hood by lots of small synthetic classes, and would therefore incur a similar performance hit.
Voters For This Link (5)
Voters Against This Link (0)