I have made the following observations Its probably not complete:-
Let us assume methods are overloaded- say we have methods method(int), method(long), method(char), method(Object), method(
String), method(Integer).
If an anonymous primitive / object is passed the method invoked will be based on the anonymous primitive / object type. If the primitive / object was not anonymous the method invoked would be based on the primitive�s variable type or object�s reference type.
If the argument is an anonymous null and there are multiple overloaded methods that take reference arguments the compiler will complain about the ambiguity since there are multiple overloaded methods that take reference arguments but there are two inheritence heirachies String->Object & Integer->Object.
If however the methods were method(int), method(long), method(char), method(Object), method(String) and the argument is an anonymous null then since there are multiple overloaded methods that take reference arguments but there is only one inheritence heirachy it will take the highest type here -String.
If there is no corresponding methods an attempt for widening conversion or upcasting will be attempted as with
polymorphism.
Otherwise the binding is compile time binding and not dynamic binding as with polymorphism