can a static method be overridden
Answer Posted / narasimha rao bodagala
Hi rama devi,u are written the answer is ok but not clear
i given one example of this
what i am saying is the static methods are not overriden
cause the class loader will load the while loading the
class at runtime so the compiler will check the which
static method would i need to call co its confused thas's
why the static methods are not overriden.
EXAMPLE:
class A {
static void something () {}
}
class B extends A {
static void something () {}
}
....
A anA = new B ();
anA.something ();
think and compile what's the comipler say's.
Is This Answer Correct ? | 18 Yes | 9 No |
Post New Answer View All Answers
What are the types of scaling?
What is the difference between the session.get() method and the session.load() method?
What is TL and its use?
What are the oops concept?
How can I scroll through list of pages like the search results in google?
What are the pros and cons of detached objects?
What happens when a thread cannot acquire a lock on an object?
In inglish: How to convert jar to exe files? Em português: Como converter arquivos .jar para .exe?
What modifiers may be used with an interface declaration?
What do you mean by Socket Programming?
Can I map more than one table in a cmp?
Why use a datasource when you can directly specify a connection details?
Why use a datasource when you can directly specify a connection details? (in a J2EE application)
What is the difference between the session.update() method and the session.lock() method?
What is table mutation and how do you avoid it?