H
heisenberg
The java compiler enforces a rule that simply stated requires that a
derived class's constructor must, upon entry, immediately call its
superclass's constructor.
I wish to insert bytecode into a set of java class constructors at load
time; Trust me when I say that it will be a far easier implementation
if my bytecode is placed at the start of the constructor (rather than
after the call to the superclass).
I have prototyped a solution using a couple of variants and they all
seem to work fine; I am, however, concerned about potential cases that
I may not be aware of.
Does anyone know of a condition in which the above implementation will
cause the application class to misbehave or fail; any comments are most
welcome.
Thanks
derived class's constructor must, upon entry, immediately call its
superclass's constructor.
I wish to insert bytecode into a set of java class constructors at load
time; Trust me when I say that it will be a far easier implementation
if my bytecode is placed at the start of the constructor (rather than
after the call to the superclass).
I have prototyped a solution using a couple of variants and they all
seem to work fine; I am, however, concerned about potential cases that
I may not be aware of.
Does anyone know of a condition in which the above implementation will
cause the application class to misbehave or fail; any comments are most
welcome.
Thanks