Hidden cost of initialization

Trick question: What is difference between these: Sample Code 1 [code lang=”java”] class FooBar { private int x = 0; [/code] Sample Code 2 [code lang=”java”] class FooBar { private int x; [/code] Q: What is difference? I.e. aren’t those pieces of code by definition exactly same, thus it doesn’t matter what you write. A:…

Read more

Real UML

My interest (after trying lots of different tools, Objecteering, ArgoUML, BoUML) into real UML tools was arised with this one: UMLet UMLet allow nice user friendly concept of editing properties of elements direcly as plain text, instead of clumsy dialogs like every other tools what I’d tried so far. However, appetite grows, and this sounds…

Read more

Duh, Don’t, now keep going on…

Seemingly there is eeny-weeny little things what could be optimized in Log4J. Re: Proposed synchronization changes log4j-dev Re: log4j multithreading performance Proposed synchronization changes By quickly looking, changes make sense, only one detail strikes me as potential problem: new logic is causing re-allocation of StringBuffer iin PatternLayout, everytime when formatting of layout is done (==…

Read more