Created new "newInstAnonClass"  method with right implementation