publicclassReflect{ publicvoidrun(int i)throws ZeroException { A b = new A(); a.run(i); } }
classA{ publicvoidrun(int i)throws ZeroException { if (i < 0) { thrownew ZeroException("Parameter must be greater than zero!"); } System.out.println("Param: " + i); } }