How to choose between two method of the same name in Java

Cast the first argument to the type of the first parameter of the method you want to call, for example:

methodName((A) null, y, z);

Leave a Comment