It's not faster. It seems to be predicated on the assumption that a method can be inlined but a constructor can't. Unfortunately that's nonsense, so the entire point of it goes out the window.
Even if this were faster, it would almost certainly be a bad idea. Code should not be optimised at the expense of readability, except in extreme circumstances where every last CPU cycle is critical, and in that case you're unlikely to be using Java.
In fact, this is worse than just being harder to read. The next refactoring will inevitably be for the Test
constructor to call the init()
method, so that it doesn't always have to be done manually (and doing it manually is a pain and a potential source of bugs if it gets forgotten); and it is bad practice if a constructor calls a method that can be overridden, because a subclass might inadvertently change what happens at construction time when the superclass constructor is called (see this question for more details). When this happens, a subclass of Test
within the same package will be able to override the init()
method, and then when the subclass invokes super()
, either implicitly or explicitly, the superclass's constructor will end up calling the overridden init()
. (This particular problem could be got rid of by declaring init()
to be private
.)
Don't do it.