Replacement of "relections" for simple java code