This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Hi I am confused static method... As per my knowledge static method neither verride nor overload but still we can inherit it.. ohk fine as per the inheritance concept if we follow that didn't it gives ambiguity in the code(which method call when??)
Static methods to be called doesn't require a instance. Even if you provide an instance for invoking, the JVM will only fetch the associated reference and call the static method on it.
new Obj() will return a reference the Obj class(obviously). JVM will use it to make the static call.