Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

can a static method be overridden

Answer Posted / abid mehmood

An instance method can not override the static method of
its parent class.like
if parenet class contains
public static void test()
{
}
then in child class you can't override like this

public void test(){ //you can't override
}
or even like this

public static int test(){ //compile time error:type is
incompatibe with parent's test method.
}

Is This Answer Correct ?    4 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between system.out ,system.err and system.in?

1164


What is ioc concept?

1268


What are the oops concept?

1136


Why use a datasource when you can directly specify a connection details?

1085


What is glasgow?

1111


What are the different approaches to represent an inheritance hierarchy?

1121


When is the best time to validate input?

1154


How task's priority is used in scheduling?

2345


whats is statement and procedure

2299


Is it possible to stop the execution of a method before completion in a sessionbean?

1150


How many times may an objects finalize() method be invoked by the garbage collector?

1145


For which statements does it make sense to use a label?

1140


Difference between loadclass and class.forname?

1099


Explain ioc concept?

1201


Which class is the immediate superclass of the menucomponent class?

1251